Part Number Hot Search : 
TB0900L A5800954 PC1488 DR204G 2SC1755 ASH1201 D3S4M10 PC1488
Product Description
Full Text Search
 

To Download A3981V Datasheet File

  If you can't view the Datasheet, Please click here to try to view without PDF Reader .  
 
 


  Datasheet File OCR Text:
  description the a3981 is a flexible microstepping motor driver with built-in translator for easy operation. it is a single-chip solution, designed to operate bipolar stepper motors in full-, half-, quarter- and sixteenth-step modes, at up to 28 v and 1.4 a. the a3981 can be controlled by simple step and direction inputs, or through the spi-compatible serial interface that also can be used to program many of the integrated features and to read diagnostic information. the current regulator can be programmed to operate in fixed off-time or fixed frequency pwm, with several decay modes to reduce audible motor noise and increase step accuracy. in addition the phase current tables can be programmed via the serial interface to create unique microstep current profiles to further improve motor performance for specific applications. the current in each phase of the motor is controlled through a dmos full bridge, using synchronous rectification to improve power dissipation. internal circuits and timers prevent cross- conduction and shoot-through, when switching between high- side and low-side drives. the outputs are protected from short circuits, and features for low load current and stalled rotor detection are included. chip-level protection includes: hot and cold thermal warnings, overtemperature shutdown, and overvoltage and undervoltage lockout. the a3981 is supplied in a 28-pin tssop power package with an exposed thermal pad (package type lp). this package is lead (pb) free with 100% matte-tin leadframe plating. a3981-ds, rev. 5 features and benefits ? peak motor current up to 1.4 a, 28 v ? low r ds(on) outputs, 0.5 source and sink, typical ? automatic current decay mode detection/selection ? mixed, fast, and slow current decay modes ? synchronous rectification for low power dissipation ? internal ovlo, uvlo, and thermal shutdown circuitry ? crossover-current protection ? short circuit and open load diagnostics ? hot and cold thermal warning ? stall detect features ? spi-compatible or simple step and direction motion control ? highly configurable via spi-compatible serial interface applications ? automotive stepper motors ? engine management ? headlamp positioning automotive, programmable stepper driver package: 28-pin tssop with exposed thermal pad (suffix lp) typical applications not to scale a3981 a utomotive 12v power net logic supply serial interface control micro- controller or ecu oap pgnd vbb osc oam obp obm stepper motor agnd vcp step dir ms0 ms1 enable re s etn sdi sdo sck strn vdd diag sensa sensb ref vreg cp1 cp2 parallel control a utomotive 12v power net logic supply or ecu oap pgnd vbb osc oam obp obm stepper motor agnd vcp step dir ms0 ms1 enable re s etn sdi sdo sck strn vdd diag sensa sensb ref vreg cp1 cp2 micro- controller
automotive, programmable stepper driver a3981 2 allegro microsystems, llc 115 northeast cutoff worcester, massachusetts 01615-0036 u.s.a. 1.508.853.5000; www.allegromicro.com selection guide part number packing* a3981klp-t 50 pieces per tube 4.4 mm 9.7 mm, 1.2 mm nominal height tssop with exposed thermal pad a3981klptr-t 4000 pieces per reel *contact allegro ? for additional packing information. absolute maximum ratings with respect to gnd characteristic symbol notes rating unit load supply voltage v bbx applies to v bba and v bbb ?0.3 to 50 v logic supply voltage v dd ?0.3 to 6 v pin cp1 ?0.3 to v bb v pins cp2, vcp ?0.3 to v bb +8 v pins step, dir, enable, diag ?0.3 to 6 v pin vreg ?0.3 to 8.5 v pin resetn can be pulled to v bb with 38 k ?0.3 to 6 v pin osc ?0.3 to 6 v pins ms0, ms1 ?0.3 to 6 v pins sdi, sdo, sck, strn ?0.3 to 6 v pin ref ?0.3 to 6 v pins oap, oam, obp, obm ?0.3 to v bb v pins sensa, sensb ?0.3 to 1 v ambient operating temperature range t a range k; limited by power dissipation ?40 to 150 c maximum continuous junction temperature t j (max) 150 c transient junction temperature t tj overtemperature event not exceeding 10 s, lifetime duration not exceeding 10 hours, guaranteed by design and characterization 175 c storage temperature range t stg ?55 to 150 c thermal characteristics may require derating at maximum conditions characteristic symbol test conditions* value unit package thermal resistance (junction to ambient) r ja 4-layer pcb based on jedec standard 28 oc/w 2-layer pcb with 24.52 cm 2 of copper area each side 32 oc/w package thermal resistance (junction to pad) r jp 2 oc/w *additional thermal information available on the allegro website
automotive, programmable stepper driver a3981 3 allegro microsystems, llc 115 northeast cutoff worcester, massachusetts 01615-0036 u.s.a. 1.508.853.5000; www.allegromicro.com dmos full bridge dmos full bridge gate drive charge pump step ref 6-bit dac 6-bit dac oscillator +- +- sensb sensa vcp vbba oap oam sensa vbbb obp obm sensb dir resetn enable vdd diag ref 3.3v vbat vbat sdi sdo sc k strn dac ref pwm control bridge control logic pwm control translator serial interface system control and registers undervoltage, overvoltage cold warning, hot warning, overtemperature short detect, open load detect stall detect d n g p d n g a regulator osc vreg pad cp2 cp1 ms1 ms0 functional block diagram
electrical characteristics 1,2 valid at t j = ?40c to 150c, v bb = 7 to 28 v, v dd = 3 to 5.5 v; unless otherwise noted characteristics symbol test conditions min. typ. max. unit automotive, programmable stepper driver a3981 4 allegro microsystems, llc 115 northeast cutoff worcester, massachusetts 01615-0036 u.s.a. 1.508.853.5000; www.allegromicro.com supplies load supply voltage range 3 v bb functional 0 ? 50 v outputs driving 7 ? v bbov v load supply quiescent current i bbq enable = 0 ? ? 4 ma sleep mode ? 1 10 a logic supply voltage range v dd 3 ? 5.5 v logic supply quiescent current i ddq enable = 0 ? ? 5 ma enable=0, v dd > 5 v ? ? 5.5 ma sleep mode, v dd = 3.3 v ? 4 15 a sleep mode, v dd = 5 v ? ? 25 a charge pump voltage v cp with repect to vbb, v bb >7.5 v, enable = 0, resetn = 1 ? 6.7 ? v internal regulator voltage v reg enable = 0, resetn = 1, v bb > 7.5 v ? 7.2 ? v internal regulator dropout voltage v regdo enable = 0, resetn = 1, v bb > 5.6 v ? 100 200 mv motor bridge output high-side on-resistance r onh v bb = 13.5 v, i out = ?1 a, t j = 25c ? 500 600 m v bb = 13.5 v, i out = ?1 a, t j = 150c ? 900 1100 m v bb = 7 v, i out = ?1 a, t j = 25c ? 625 750 m high-side body diode forward voltage v fh i f = 1 a ? ? 1.4 v low-side on-resistance r onl v bb = 13.5 v, i out = 1 a, t j = 25c ? 500 600 m v bb = 13.5 v, i out = 1 a, t j = 150c ? 900 1100 m v bb = 7 v, i out = 1 a, t j = 25c ? 625 750 m low-side body diode forward voltage v fl i f = ?1 a ? ? 1.4 v output leakage current i lo enable = 0, resetn = 1, v o = v bb ?120 ?65 ? a enable = 0, resetn = 1, v o = 0 v ?200 ?120 ? a enable = 0, resetn = 0, v o = v bb ? <1.0 20 a enable = 0, resetn = 0, v o = 0 v ?20 <1.0 ? a current control internal oscillator frequency f osc osc = agnd 3.2 4 4.8 mhz 51 k from osc to vdd 3.6 ? 4.4 mhz external oscillator frequency range f ext 3?5mhz blank time 4 t blank default blank-time ? 1500 ? ns off-time (in fixed off-time mode) 4 t off default off-time ? 44 ? s pwm frequency (in fixed frequency mode) 4 f pwm default pwm frequency ? 16.7 ? khz continued on the next page?
electrical characteristics 1,2 (continued) valid at t j = ?40c to 150c, v bb = 7 to 28 v, v dd = 3 to 5.5 v; unless otherwise noted characteristics symbol test conditions min. typ. max. unit current control (continued) fast decay time 4 t fast default fast decay time ? 8 ? s reference input voltage v ref 0.8 ? 2 v internal reference voltage v refint ref tied to vdd 1.1 1.2 1.3 v current control (continued) reference input current i ref ?3 0 3 a maximum sense voltage v smax ? 125 ? mv current trip point error 5 e itrip v ref = 2 v, mxi0 = mxi1 = 1 ? ? 5 % logic input and output ? dc parameters input low voltage v il ? ? 0.3 v dd v v dd > 4.5 v ? ? 0.28 v dd v input high voltage v ih 0.7 v dd ??v input hysteresis v ihys 250 500 ? mv input current (except resetn) i in 0 v < v in < v dd ?1 ? 1 a input pull-down resistor (resetn) r pd ?50?k output low voltage v ol i ol = 2 ma ? 0.2 0.4 v output high voltage v oh i ol = ?2 ma v dd ?0.4 v dd ?0.2 ? v output leakage (sdo) i o 0 v < v o < v dd , strn = 1 ?1 ? 1 a logic input and output ? dynamic parameters reset pulse width t rst 0.2 ? 4.5 s reset shutdown width t rsd 10 ? ? s input pulse filter time (step, dir) t pin ?35?ns clock high time t sckh a in figure 1 50 ? ? ns clock low time t sckl b in figure 1 50 ? ? ns strobe lead time t stld c in figure 1 30 ? ? ns strobe lag time t stlg d in figure 1 30 ? ? ns strobe high time t strh e in figure 1 300 ? ? ns data out enable time t sdoe f in figure 1 ? ? 40 ns data out disable time t sdod g in figure 1 ? ? 30 ns data out valid time from clock falling t sdov h in figure 1 ? ? 40 ns data out hold time from clock falling t sdoh i in figure 1 5 ? ? ns data in set-up time to clock rising t sdis j in figure 1 15 ? ? ns data in hold time from clock rising t sdih k in figure 1 10 ? ? ns step rising to strn rising setup time t sps l in figure 1, only when d15 = 1 and d14 = 0 100 ? ? ns step rising from strn rising hold time t sph m in figure 1, only when d15 = 1 and d14 = 0 300 ? ? ns automotive, programmable stepper driver a3981 5 allegro microsystems, llc 115 northeast cutoff worcester, massachusetts 01615-0036 u.s.a. 1.508.853.5000; www.allegromicro.com continued on the next page?
logic input and output ? dynamic parameters (continued) step low time t stph 1?? s setup time control input change to step t su ms1, ms2, dir 200 ? ? ns hold time control input change from step t h ms1, ms2, dir 200 ? ? ns wake-up from reset t en ??1ms diagnostics and protection vbb overvoltage threshold v bbov v bb rising 32 34 36 v vbb overvoltage hysteresis v bbovhys 2?4v vreg undervoltage threshold v reguv v reg falling 5.1 ? 5.4 v vreg undervoltage hysteresis v rguvhys ?1?v vdd undervoltage threshold v dduv v dd falling 2.6 ? 2.9 v vdd undervoltage hysteresis v dduvhys 50 100 ? mv osc timeout t wd bit 13 = 1 0.5 1 1.5 s high-side overcurrent threshold i och sampled after t sct 1.4 2.05 2.65 a high-side current limit i limh active during t sct 3 5.5 8 a low-side overcurrent sense voltage v ocl sampled after t sct 210 250 290 mv overcurrent fault delay t sct default fault delay 1500 2000 2700 ns open load current threshold error e ioc v ref = 2 v, mx0 = mx1 = 1 ? ? 10 % temperature voltage output offset v to temperature output selected on diag pin ? 1440 ? mv temperature voltage output slope a t ? ?3.92 ? mv/c cold temperature warning threshold t jwc temperature decreasing ?20 ?10 0 oc cold temperature warning hysteresis t jwchys ?15?oc hot temperature warning threshold t jwh temperature increasing 125 135 145 oc hot temperature warning hysteresis t jwhhys ?15?oc overtemperature shutdown threshold t jf temperature increasing 155 170 ? oc overtemperature hysteresis t jhys recovery = t jf ? t jhys ?15?oc 1 for input and output current specifications, negative current is defined as coming out of (sourcing) the specified device pin. 2 all references to ?vbb? apply to vbba and vbbb. 3 function is correct but parameters are not guaranteed above or below the general limits (7 to 28 v). outputs not operational ab ove v bbov or below v reguvl . 4 assumes a 4 mhz clock. 5 current trip point error is the difference between actual current trip point and the target current trip point, referred to max imum full scale (100%) current: e itrip = 100 [i tripactual ? i triptarget ] / i fullscale (%). electrical characteristics 1,2 (continued) valid at t j = ?40c to 150c, v bb = 7 to 28 v, v dd = 3 to 5.5 v; unless otherwise noted characteristics symbol test conditions min. typ. max. unit automotive, programmable stepper driver a3981 6 allegro microsystems, llc 115 northeast cutoff worcester, massachusetts 01615-0036 u.s.a. 1.508.853.5000; www.allegromicro.com
figure 1. serial interface timing diagram figure 2. control input interface timing diagram c a b d e j k f i g 0 d 4 1 d 5 1 d ' 0 d ' 4 1 d ' 5 1 d strn sck sdi sdo h z step l m no rise when d15=1 and d14=0 z x x xx key characteristic key characteristic a clock high time h data out valid time from clock falling b clock low time i data out hold time from clock falling c strobe lead time j data in set-up time to clock rising d strobe lag time k data in hold time from clock rising e strobe high time l step rising to strn rising setup time f data out enable time m step rising from strn rising hold time g data out disable time x ?don?t care? z high-impedance (tristate) step dir, ms0, ms1 t stpl t stph t h t su resetn t en enable* * enable ( pin ) or run [ en ] bit automotive, programmable stepper driver a3981 7 allegro microsystems, llc 115 northeast cutoff worcester, massachusetts 01615-0036 u.s.a. 1.508.853.5000; www.allegromicro.com
automotive, programmable stepper driver a3981 8 allegro microsystems, llc 115 northeast cutoff worcester, massachusetts 01615-0036 u.s.a. 1.508.853.5000; www.allegromicro.com functional description the a3981 is an automotive stepper motor driver suitable for high temperature applications such as headlamp bending and leveling, throttle control, and gas recirculation control. it is also suitable for other low current stepper applications such as air con- ditioning and venting. it provides a highly flexible microstepping motor driver that can be configured via the spi-compatible serial interface. it can be controlled with simple step and direction inputs, for high speed stepping applications, or directly through the serial interface by writing a step change value. the two dmos full bridges are capable of driving bipolar step- per motors in full-, half-, quarter-, eighth- and sixteenth-step modes, at up to 28 v and 1.4 a. the current in each phase of the stepper motor is regulated by a peak detect pwm current control scheme that can be programmed to operate in fixed off-time or fixed frequency. several decay modes can be selected to reduce audible motor noise and increase step accuracy. in addition the phase current tables, which default to a sinusoidal current profile, can be programmed via the serial interface to create unique microstep current profiles to further improve motor performance for specific applications. the outputs are protected from short circuits, and features for open load and stalled rotor detection are included. chip level pro- tection includes hot and cold thermal warning, overtemperature shutdown, and overvoltage and undervoltage lockout. pin functions vbba, vbbb main motor supply and chip supply for internal regulators and charge pump. vbba and vbbb should be con- nected together and each decoupled to ground with a low esr electrolytic capacitor and a good ceramic capacitor. note: any reference to ?vbb? in this specification is defined as applying to both vbba and vbbb. cp1, cp2 pump capacitor connection for charge pump. connect a 100 nf (50 v) ceramic capacitor between cp1 and cp2. vcp above-supply voltage for high-side drive. a 100 nf (16 v) ceramic capacitor should be connected between vcp and vbb to provide the pump storage reservoir. vdd logic supply. compatible with 3.3 v and 5 v logic. should be decoupled to ground with a 100 nf (10 v) ceramic capacitor. vreg regulated supply for bridge gate drive. should be decou- pled to ground with a 470 nf (10 v) ceramic capacitor. agnd analog reference ground. quiet return for measurement and input references. connect to pgnd (see layout section). pgnd digital and power ground. connect to supply ground and agnd (see layout section). oap, oam motor connection for phase a. positive motor phase current direction is defined as flowing from oam to oap. obp, obm motor connection for phase b. positive motor phase current direction is defined as flowing from obm to obp. sensa phase a current sense. connect sense resistor between sensa and pgnd. sensb phase b current sense. connect sense resistor between sensb and pgnd. ref reference input to set absolute maximum current level for both phases. defaults to internal reference when tied to vdd. step step logic input. motor advances on rising edge. filtered input with hysteresis. dir direction logic input. direction changes on the next step rising edge. when high, the phase angle number is increased on the rising edge of step. has no effect when using the serial interface. filtered input with hysteresis. ms0 microstep resolution select input. ms1 microstep resolution select input. resetn resets faults when pulsed low. forces low-power shut- down (sleep) when held low for more than the reset shutdown width, t rsd . can be pulled to vbb with 30 k resistor. enable controls activity of bridge outputs. when held low, deactivates the outputs, that is, turns off all output bridge fets. internal logic continues to follow input commands. sdi serial data input. 16-bit serial word input msb first. sdo serial data output. high impedance when strn is high. out- puts bit 15 of the diagnostic registers (fault register 0 and fault register 1), the fault register flag, as soon as strn goes low. sck serial interface clock. data is latched in from sdi on the rising edge of the sck clock signal. there must be 16 rising edges per write and sck must be held high when strn changes. strn serial data strobe and serial access enable. when strn is high any activity on sck or sdi is ignored, and sdo is high
automotive, programmable stepper driver a3981 9 allegro microsystems, llc 115 northeast cutoff worcester, massachusetts 01615-0036 u.s.a. 1.508.853.5000; www.allegromicro.com impedance allowing multiple sdi slaves to have common sdi, sck, and sdo connections. diag diagnostic output. function selected via the serial inter- face, setting configuration register 1. default is fault output. osc with bit 13 in configuration register 1 set to 0, either con- nect this pin to agnd to use the internal oscillator running at the default frequency of 4 mhz, or connect a resistor to vdd to set the internal oscillator frequency. ( the approximate frequency is calculated from: f osc = 10 000 / (48 r osc ? 20) where f osc is the internal oscillator frequency in mhz, and r osc is the value, in k of the resistor between osc and vdd.) if bit 13 in configuration register 1 is set to 1, then osc is the input for an external system clock, which must have a frequency between 3 and 5 mhz. in this mode a watchdog is provided to detect loss of the system clock. if the osc pin remains high or low for more than the watchdog time, t wd , 1 s typical, then the fault register flag (bit 15 in the diagnostic registers) is set and the outputs are disabled until the clock restarts. driving a stepper motor a two-phase stepper motor is made to rotate by sequencing the relative currents in each phase. in its simplest form, each phase is simply fully energized in turn by applying a voltage to the winding. for more precise control of the motor torque over temperature and voltage ranges, current control is required. for efficiency this is usually accomplished using pulse width modula- tion (pwm) techniques. in addition current control also allows the relative current in each phase to be controlled, providing more precise control over the motor movement and hence improve- ments in torque ripple and mechanical noise. further details of stepper motor control are provided in appendix a. for bipolar stepper motors the current direction is significant, so the voltage applied to each phase must be reversible. this requires the use of a full bridge (also known as an h-bridge) which can switch each phase connection to supply or to ground. phase current control in the a3981, current to each phase of the two-phase bipolar stepper motor is controlled through a low impedance n-channel dmos full bridge. this allows efficient and precise control of the phase current using pwm switching. the full-bridge con- figuration provides full control over the current direction during the pwm on-time, and over the current decay mode during the pwm off-time. due to the flexibility of the a3981 these control techniques can be completely transparent to the user or can be partially- or fully-programmed through the serial interface. each leg (high-side, low-side pair) of a bridge is protected from shoot-through by a fixed dead time. this is the time between switching off one fet and switching on the complementary fet. cross-conduction is prevented by lock-out logic in each driver pair. the phase currents and in particular the relative phase currents are defined in the phase current table (table 7). this table defines the two phase currents at each microstep position. for each of the two phases, the currents are measured using a sense resistor, r s , with voltage feedback to the respective sensx pin. the target current level is defined by the voltage from the digital-to-analog converter (dac) for that phase. the sense voltage is amplified by a fixed gain and compared to the output of the dac. there are two types of maximum current : the absolute maximum, i smax , the maximum possible current defined by the sense resis- tor and the reference input; and the phase maximum, i pmax , the maximum current delivered to a motor phase. the absolute maximum current, i smax , is defined as: i smax = v ref / (16 r s ) where v ref is the voltage at the ref pin, and r s is the sense resistor value. the phase maximum, i pmax , is the 100% reference level for the phase current table and may be a fraction of the absolute maxi- mum current, i smax , depending on the value of the mxi0 and mxi1 bits in configuration register 0. for example: ? if r s = 180 m and v ref = 2 v, then i smax = 694 ma ? if mxi1= 1 and mxi0 = 0, then i pmax = 520 ma the actual current delivered to each phase at each step angle number is determined by the value of i pmax and the contents of the phase current table. for each phase, the value in the table is passed to the dac, which uses i pmax as the reference 100% level (code 63) and reduces the current target depending on the dac code. the output from the dac is used as the input to the current comparators. the current comparison is ignored at the start of the pwm on-time for a duration referred to as the blank time . the blank time is necessary to prevent any capacitive switching currents from causing a peak current detection. the pwm on-time starts at the beginning of each pwm period. the current rises in the phase winding until the sense voltage reaches the required current level. at this point the pwm off-time
automotive, programmable stepper driver a3981 10 allegro microsystems, llc 115 northeast cutoff worcester, massachusetts 01615-0036 u.s.a. 1.508.853.5000; www.allegromicro.com starts and the bridge is switched into one of two decay modes, slow decay or fast decay : ? slow decay is most effective when the current is rising from step to step, and it occurs when the phase winding is effectively shorted by switching-on either both high-side fets or both low- side fets in the full bridge. ? fast decay is most effective when the current is falling from step to step, and it occurs when the voltage on the phase is reversed. one disadvantage of fast decay is the increased current ripple in the phase winding. however, this can be reduced while main- taining good current control, by using a short time of fast decay followed by slow decay for the remainder of the pwm off-time. this technique is commonly referred to as mixed decay. the a3981 provides two methods to determine the pwm frequency: fixed off-time and fixed frequency. at power-up the default mode is fixed off-time. fixed frequency can be selected through the serial interface. fixed off-time provides a marginal improvement in current accuracy over a wide range of current levels. fixed frequency provides a fixed fundamental frequency to allow more precise supply filtering for emc reduction. in both cases the pwm off-time will not be present if the peak current limit is not attained during the pwm on-time. phase current table the relative phase currents are defined by the phase current table (table 7). this table contains 64 lines and is addressed by the step angle number, where step angle number 0 corresponds to 0 or 360. the step angle number is generated internally by the step sequencer, which is controlled either by the step and dir inputs or by the step change value from the serial input. the step angle number determines the motor position within the 360 electri- cal cycle and a sequence of step angle numbers determines the motor movement. note that there are four full mechanical steps per 360 electrical cycle. each line of the phase current table (table 7) has a 6-bit value per phase to set the dac level for that phase, plus an additional bit per phase to determine the current direction for that phase. the step angle number sets the electrical angle of the stepper motor in one-sixteenth microsteps, approximately equivalent to electri- cal steps of 5.625. on first power-up or after a vdd power-on reset, the phase cur- rent table values are reset to define a sinusoidal current profile and the step angle number is set to 8, equivalent to the electri- cal cycle 45 position. this position is defined as the ?home? position. the maximum current in each phase, i pmax , is defined by the sense resistor and the maximum current setting (bits mxi[0..1]) in configuration register 0. the phase currents for each entry in the phase current table are expressed as a percent- age of this maximum phase current. when using the step and dir inputs to control the stepper motor, the a3981 automatically increases or decreases the step angle number according to the step sequence associated with the selected step mode. the default step mode, reset at power- up or after a power on reset, is full step. half-, quarter-, and sixteenth-step sequences are also available when using the step and dir inputs, and are selected using the logical or of the ms0 and ms1 inputs and the ms0 and ms1 bits in configuration reg- ister 0. the eighth-step sequence is shown in the phase current table for reference only. when using the serial interface to control the stepper motor, a step change value (6-bit) is input through the serial interface to increase or decrease the step angle number. the step change value is a two?s complement (2?sc) number, where a positive value increases the step angle and a negative value decreases the step angle. a single step change in the step angle number is equivalent to a single one-sixteenth microstep. therefore, for cor- rect motor movement, the step change value should be restricted to no greater than 16 steps, positive or negative. this facility enables full control of the stepper motor at any microstep resolution up to and including sixteenth-step, plus the ability to change microstep resolution ?on-the-fly? from one microstep to the next. in both control input method cases, the resulting step angle number is used to determine the phase current value and current direction for each phase, based on the phase current table. the decay mode is determined by the position in the phase current table and the intended direction of rotation of the motor. diagnostics the a3981 integrates a number of diagnostic features to protect the driver and load as far as possible from fault conditions and extreme operating environments. at the system level the supply voltages and the chip temperature are monitored. a number of these features automatically disable the current drive to protect the outputs and the load. others only provide an indication of the likely fault status, as shown in the fault table (table 1). a single diagnostic output pin (diag) can be programmed through the serial interface to provide several different internal signals. at power-up, or after a power-on-reset the diag pin outputs a simple fault output flag which will be low if a fault is present. the fault output flag remains low while the fault is present or if one of the latched faults (for example, a bridge short circuit) has been detected and the outputs disabled.
automotive, programmable stepper driver a3981 11 allegro microsystems, llc 115 northeast cutoff worcester, massachusetts 01615-0036 u.s.a. 1.508.853.5000; www.allegromicro.com alternative to the fault output flag, the diag output can be pro- grammed via the serial interface to output: the stall detect signal, which goes low when a stall is detected; the phase a pwm-on signal, which is high during the phase a pwm on-time; or an analog signal indicating the silicon temperature. if required, specific fault information can be determined by read- ing the diagnostic registers (see serial interface section). the first bit (bit 15) in both diagnostic registers contains a com- mon fault register flag which will be high if any of the fault bits in either register has been set. this allows a fault condition to be detected using the serial interface, by simply taking strn low. as soon as strn goes low the fist bit in the diagnostic registers can be read to determine if a fault has been detected at any time since the last diagnostic registers reset. in all cases the fault bits in the diagnostic registers are latched and only cleared after a diagnostic registers reset. note that the fault register flag in the diagnostic registers, does not provide the same function as the fault output flag on the diag pin. the fault output flag on the diag pin provides an indication that either a fault is present or the outputs have been disabled due to a short circuit fault. the fault register flag sim- ply provides an indication that a fault has occurred since the last diagnostic registers reset and has been latched. at the system level the supply voltages and chip temperature are monitored. supply voltage monitors the logic supply, the motor supply, and the regulator output are monitored: the motor supply for overvoltage, and the regulator output and logic supply for undervoltage. ? if the motor supply voltage, v bba and v bbb , goes above the vbb overvoltage threshold, the a3981 will disable the outputs and indicate the fault. when the motor supply voltage goes be- low the vbb overvoltage threshold, the outputs will be re-en- abled and the fault flag removed. the fault bits in the diagnostic registers remain set until cleared by a diagnostic registers reset. ? if the motor supply voltage, v bba and v bbb , goes below the vbb undervoltage threshold, the a3981 will indicate the fault and reduce the vreg undervoltage threshold to the low level. when the motor supply voltage goes above the vbb under- voltage threshold, the vreg undervoltage threshold will be increased to the high level and the fault flag removed. the fault bits in the diagnostic registers remain set until cleared by a diagnostic registers reset. ? if the output of the internal regulator, v reg , goes below the vreg undervoltage threshold, the a3981 will disable the outputs and indicate the fault. when the regulator output rises above the vreg undervoltage threshold, the outputs will be re-enabled and the fault flag removed. the fault bits in the diag- nostic registers remain set until cleared by a diagnostic registers reset. ? if the logic supply voltage, v dd , goes below the vdd under- voltage threshold, the a3981 will be completely disabled except to monitor the v dd voltage level. when the logic supply voltage rises above the vdd undervoltage threshold, a power-on reset will take place and all registers will be reset to the default state. note that both the vreg undervoltage monitor and the v bb undervoltage monitor indicate a fault by using the same fault bit, uv, in both fault registers. the state of the uv fault bit is determined by the logical or of the fault output from these two undervoltage monitors. temperature monitors three specific temperature thresholds are provided: a hot warning, a cold warning, and an overtemperature shutdown. in addition, the analog internal signal used to determine the chip temperature can be selected in configuration register 1 as the output on the diag pin through the serial interface. the analog scale is t j (v diag ? v to ) / a t . table 1. fault table diagnostic action latched vbb overvoltage disable outputs, set fault register flag no vreg undervoltage disable outputs, set fault register flag no vdd undervoltage power-down, full reset no temperature warning set fault register flag no overtemperature disable outputs, set fault register flag no bridge short disable outputs, set fault register flag yes bridge open set fault register flag no stall detect set st flag no
automotive, programmable stepper driver a3981 12 allegro microsystems, llc 115 northeast cutoff worcester, massachusetts 01615-0036 u.s.a. 1.508.853.5000; www.allegromicro.com hot warning if the chip temperature rises above the hot tem- perature warning threshold, t jwh , the fault flag will go low and the hot warning bits will be set in the diagnostic registers. no action will be taken by the a3981. when the temperature drops below the hot temperature warning threshold, the fault flag will go high but the hot warning bits remain set in the diagnostic registers until reset. cold warning if the chip temperature falls below the cold temperature warning threshold, t jwc , the fault flag will go low and the cold warning bits will be set in the diagnostic registers. no action will be taken by the a3981. when the temperature rises above the cold temperature warning threshold, the fault flag will go high but the cold warning bits remain set in the diagnos- tic registers until reset. overtemperature shutdown if the chip temperature rises above the overtemperature shutdown threshold, t jf , the fault flag will go low and the thermal shutdown bits will be set in the diagnostic registers. the a3981 will disable the outputs to try to prevent a further increase in the chip temperature. when the tem- perature drops below the overtemperature shutdown threshold, the fault flag will go high but the thermal shutdown bits remain set in the diagnostic registers until reset. bridge and output diagnostics the a3981 includes monitors that can detect a short to supply or a short to ground at the motor phase connections. these condi- tions are detected by monitoring the current from the motor phase connections through the bridge to the motor supply and to ground. low current comparators and timers are provided to help detect possible open load conditions. short to supply a short from any of the motor connections to the motor supply (vbba or vbbb) is detected by monitoring the voltage across the low-side current sense resistor in each bridge. this gives a direct measurement of the current through the low side of the bridge. when a low-side fet is in the on state, the voltage across the sense resistor, under normal operating conditions, should never be more than the maximum sense voltage, v smax . in this state, an overcurrent is determined to exist when the voltage across the sense resistor exceeds the low-side overcurrent sense voltage, v ocl , typically 2 v smax . this overcurrent must be continu- ously present for at least the overcurrent fault delay, t sct , before the short fault is confirmed by setting the relevant bit in fault0 and driving the diag output low if the fault output flag is selected. the output is switched off and remains off until a fault reset occurs. note that the sense resistor cannot distinguish which low-side fet is in an overcurrent state. so, if more than one low-side fet is active when the fault is detected, for example during low-side recirculation with synchronous rectification, then the shorted con- nection is determined from the internal pwm state. the actual overcurrent that v ocl represents is determined by the value of the sense resistor and is typically 2 i smax . short to ground a short from any of the motor connections to ground is detected by directly monitoring the current through each of the high-side fets in each bridge. when a high-side fet is in the on state the maximum current is typically always less than 1 a. in this state, an overcurrent is determined to exist when the current through the active high-side fet exceeds the high-side overcurrent threshold, i och . this overcurrent must be present for at least the overcurrent fault delay, t sct , before the short fault is confirmed by setting the relevant bit in fault0 and driving the diag output low if the fault output flag is selected. the output is switched off and remains off until a fault reset occurs. note that when a short to ground is present the current through the high-side fet is limited to the high-side current limit, i limh , during the overcurrent fault delay, t sct . this prevents large negative transients at the phase output pins when the out- puts are switched off. shorted load a short across the load is indicated by concurrent short faults on both high side and low side. short fault blanking all overcurrent conditions are ignored for the duration of the overcurrent fault delay, t sct . the short detection delay timer is started when an overcurrent first occurs. if the overcurrent is still present at the end of the short detection delay time then a short fault will be generated and latched. if the overcurrent goes away before the short detection delay time is complete, then the timer is reset and no fault is generated. this prevents false short detection caused by supply and load transients. it also prevents false short detections resulting from current transients generated by the motor or wiring capacitance when a fet is first switched on. short fault reset and retry when a short circuit has been detected all outputs for the faulty phase are disabled until the
automotive, programmable stepper driver a3981 13 allegro microsystems, llc 115 northeast cutoff worcester, massachusetts 01615-0036 u.s.a. 1.508.853.5000; www.allegromicro.com next occurrence of: the next rising edge on the step input, the resetn input is pulsed low, or until the diagnostic registers are reset by writing to one of the registers through the serial interface. at the next step command or after a fault reset, the fault register flag is cleared, the outputs are re-enabled, and the voltage across the fet is resampled. note that the diagnostic registers are not cleared by the rising edge of the step input. while the fault persists the a3981 will continue this cycle, enabling the outputs for a short period then disabling the out- puts. this allows the a3981 to handle a continuous short circuit without damage. if, while stepping rapidly, a short circuit appears and no action is taken, the repeated short circuit current pulses will eventually cause the temperature of the a3981 to rise and an overtemperature fault will occur. open load detection open load conditions are detected by monitoring the phase current when the phase dac value is greater than 31. the open load current threshold, i ol , is defined by the ol0 and ol1 bits in the run register as a percent- age of the maximum (100%) phase current, i pmax , defined in the phase current table. the 100% level in the phase current table is defined by the sense resistor value and the contents of the mxi0 and mxi1 bits in configuration register 0. for example: ? if r s = 180 m and v ref = 2 v, then i smax = 694 ma ? if mxi1 = 1 and mxi0 = 0, then i pmax = 520 ma ? if ol1=0 and ol0=1, then i ol = 156 ma the open load current monitor is only active after a blank time from the start of a pwm cycle. an open load can only be detected if the dac value for the phase is greater than 31 and the current has not exceeded the open load current threshold for more than 15 pwm cycles. the a3981 continues to drive the bridge outputs under an open load condition and clears the fault register flag as soon as the phase current exceeds the open load current threshold or the dac value is less than 32. the diagnostic registers retain the open load fault bits, ola and olb, and will not be cleared until resetn is pulsed low or one of the diagnostic registers is written through the serial interface. stall detection a pwm monitor feature is included in the a3981 to assist in determining the stall condition of the stepper motor. a stalled motor condition is when the phase currents are being sequenced to step the motor but the motor remains station- ary. this can be due to a mechanical blockage such as an end stop or it can be due to the step sequence exceeding the motor capabil- ity for the attached load. reliable stall detection in a simple step- per driver is only possible by combining the pwm monitor with a continuous step sequence at a sufficiently high step rate. when a motor is stopped or moving slowly there is no back emf to impede the current in the phase windings. this allows the current to rise to the limit quickly and the pwm current control to activate. however, when a motor is running at speed the back emf, generated by the speed of the magnetic poles in the motor passing the phase windings, acts against the supply voltage and reduces the rise time of the phase current. therefore the pwm current control takes longer to activate. assuming a constant step rate, this results in fewer pwm cycles for each step of the motor. the a3981 uses this difference to detect a motor changing from continuous stepping to stalled. two pwm counters, one for each phase, accumulate the number of pwm cycles when the phase current is stepped from zero to full current. at the end of each phase current rise, the counter for that phase is compared to the counter for the previous current rise, in the opposite phase. if the difference is greater than the number in the pwm compare regis- ter, then the st bit in the diagnostic registers is set. in addition, if the st signal is selected as the output on the diag pin, then the pin will go low. this stall detection scheme assumes a number of factors: ? the motor must be stepping fast enough for the back emf to reduce the phase current slew rate. stall detection reliability improves as the current slew rate reduces. ? the motor is not being stepped in full step mode. ? the phase current table must conform to the 0% and 100% conditions at steps 0, 16, 32, and 48. ? the phase current profiles must be the same for both phases. although stall detection cannot be guaranteed using this detection method, good stall detection reliability can be achieved by careful selection of motor speed, count difference, and by conforming to the above factors. in addition to using the integrated features of the a3981, it is also possible to perform stall detection by examining the pwm on-time for a single phase using an external microcontroller. in the a3981 the pwm-on signal for phase a can be selected as the output on the diag pin, by using the serial interface.
automotive, programmable stepper driver a3981 14 allegro microsystems, llc 115 northeast cutoff worcester, massachusetts 01615-0036 u.s.a. 1.508.853.5000; www.allegromicro.com serial interface description a three wire synchronous serial interface, compatible with spi, can be used to configure and control all the features of the a3981. a fourth wire can be used to provide diagnostic feedback. the registers that are accessible through the serial interface are defined in table 2. the a3981 can be operated without using the serial interface, by using the default configuration and control register settings and the step and dir logic inputs for motor control. however, application-specific configurations are only possible by setting the appropriate register bits through the serial interface. in addi- tion to setting the configuration bits, the serial interface can also be used to control the motor directly. the serial interface timing requirements are specified in the elec- trical characteristics table, and illustrated in figure 1. writing to configuration and control registers when writing to the serial register, data is received on the sdi pin and clocked through a shift register on the rising edge of the clock signal input on the sck pin. strn is normally held high, and is only brought low to initiate a serial transfer. no data is clocked through the shift register when strn is high, thus allow- ing multiple sdi slave units to use common sdi, sck, and sdo connections. each independent slave requires a dedicated strn connection. the serial data word has 16 bits, msb input first. after 16 data bits have been clocked into the shift register, strn must be taken high to latch the data into the selected register. when this occurs, the internal control circuits act on the new configuration and control data, and the diagnostic registers are reset. table 2. serial register definition* 15 14 13 12 11 10 9 8 7 6 5 4 3 2 1 0 configuration and control registers (write) configuration register 0 (config0) 00 syr ms1 ms0 mxi1 mxi0 pfd2 pfd1 pfd0 tbk1 tbk0 tof2 tof1 tof0 pwm frq2 frq1 frq0 1 0011100011100 configuration register 1 (config1) 01 osc tsc1 tsc0 cd3 cd2 cd1 cd0 diag1 diag0 010 00000 100000 run register (run) 10 en ol1 ol0 hlr slew brk dcy1 dcy0 sc5 sc4 sc3 sc2 sc1 sc0 00101001000000 table load register (tblld) 11 ptp pt5 pt4 pt3 pt2 pt1 pt0 0000000 1000101 diagnostic registers (read) fault register 0 (fault0) ff tw1 tw0 ov uv st olb ola bml bmh bpl bph aml amh apl aph fault register 1 (fault1) ff tw1 tw0 ov uv st olb ola 00 sa5 sa4 sa3 sa2 sa1 sa0 *power-on reset value shown below each input register bit.
automotive, programmable stepper driver a3981 15 allegro microsystems, llc 115 northeast cutoff worcester, massachusetts 01615-0036 u.s.a. 1.508.853.5000; www.allegromicro.com if there are more than 16 rising edges on sck, or if strn goes high and there are fewer than 16 rising edges on sck, the write will be cancelled without writing data to the configuration and control registers. in addition the diagnostic registers will not be reset. instead the ff bit will be set to 1 in the diagnostic registers, to indicate a data transfer error. the first two bits of the serial word are used to select the register to be written. this provides access to four writable registers: ? the configuration registers are used for system configuration: config0 for system parameters, and config1 for system and diagnostic parameters. ? the run register contains motor drive settings used to control the motor movement and phase current. ? the fourth writable register, tblld, is a port that allows se- quential loading of the 16 distinct phase current table settings. reading from diagnostic registers in addition to the writable registers there are two diagnostic registers. the first eight (most significant) bits of both diagnostic registers contain the same flags, only the last eight (least signifi- cant) bits differ, as follows: ? fault0 contains the short-circuit fault flags ? fault1 contains the present step angle number each time a configuration and control register is written, one of the diagnostic registers can be read, msb first, on the serial output pin, sdo (see timing in figure 1). fault1 is made the active register for serial transfer and output on sdo only while config1 is being written, that is, only when the first bit of the input word is 0 and the second bit is 1. fault0 is the active register for serial transfer and output on sdo during writes to any other configuration or control register. when strn goes low to start a serial write, sdo comes out of its high impedance state and outputs the serial register fault register flag. this allows the main controller to poll the a3981 through the serial interface to determine if a fault has been detected. if no faults have been detected then the serial transfer may be termi- nated without generating a serial read fault by ensuring that sck remains high while strn is low. when strn goes high the trans- fer will be terminated and sdo will go into its high impedance state. configuration and run registers these registers are used for system configuration and motor con- trol. access is described in the section writing to configuration and control registers, above. config0 sets certain system parameters, and config1 sets system and diagnostic output selection parameters. the run register contains motor drive settings used to control the motor movement and phase current. phase table load register this is one of the configuration and control registers, accessed when both address bits are 1. it can be used to write a sequence of values to the phase current table in the a3981. this allows the current at each step angle number to be tailored to suit the microstep current profile requirements of a specific motor. in most cases this feature will not be required and the default sinusoidal profile will suffice. however for some motor / load combinations, altering the current profile can improve torque ripple, resulting in lower mechanical vibration and noise. although the phase current table contains 64 entries for each of two phases, only 16 distinct values are required. these 16 values correspond to one quadrant of the table for a single phase, and they are repeated for the other three quadrants and again for the four quadrants of the other phase. so each of the 16 values writ- ten to the phase table load register are written to 8 locations in the phase current table. the 16 values must be entered by sequential writes to the phase table load register. the first write to the register after writing to any other register, or after a reset (resetn pulse low or power- on), puts that value, pt[5..0], into the first phase table address, a 6-bit field defined as pt(0). subsequent writes put values into successive addresses: pt(1), pt(2), and so forth up to pt(15). after the sixteenth value has been written, no more values are accepted and any writes to the phase table load register are ignored. as each value is received, it is effectively distributed to all eight required locations in the phase current table.
automotive, programmable stepper driver a3981 16 allegro microsystems, llc 115 northeast cutoff worcester, massachusetts 01615-0036 u.s.a. 1.508.853.5000; www.allegromicro.com an optional simple odd parity scheme is included to provide some measure of error checking, if required. each 6-bit value can be supplemented with an additional parity bit, ptp, to ensure an odd number of 1s in the transmission. this is checked by the a3981 and if a the number of 1s in the value plus parity bit is not odd, the ff bit will be set and the sdo pin will go high the next time strn is taken low, indicating a parity error. that data will still be written to the next phase table value address; it is incum- bent upon the external controller to take action, if required. if the write sequence is broken (by a reset, by writing to another register, or by a data transfer error) before the sequence has been completed, then the phase table value address will be reset to pt(0). if it is required to load the table, then the entire 16-value sequence must be sent. after loading, although the phase current table is volatile, a reset using a low pulse on the resetn pin does not corrupt the table. the table is only reset to default values on a power-on reset. diagnostic registers the diagnostic registers comprise two read-only fault data regis- ters. access is described in the section reading from diagnostic registers, above. the diagnostic registers contain fault flags for each fault condi- tion and are reset to all 0s on the completion of each serial access. they are also reset to all 0s each time the resetn input is low for longer than the reset pulse width, t rst . fault0 is set to all 1s at power-up or after a power-on reset. this indicates to the external controller that a power-on reset has taken place and all registers have been reset. note that a power-on reset occurs when the v dd supply rises above its undervoltage threshold . power-on reset function is not affected by the state of the motor supply or v reg . the first bit in both registers is the fault register flag, ff. this is high if any bits in fault0 are set, or if a serial write error or parity error has occurred.
automotive, programmable stepper driver a3981 17 allegro microsystems, llc 115 northeast cutoff worcester, massachusetts 01615-0036 u.s.a. 1.508.853.5000; www.allegromicro.com 1514131211109876543210 config 0 0 0 syr ms1 ms0 mxi1 mxi0 pfd2 pfd1 pfd0 tbk1 tbk0 tof2 frq2 tof1 frq1 tof0 frq0 pwm 10011100011100 configuration register 0 pwm pwm configuration pwm mode default 0 fixed off-time d 1 fixed frequency tof[2..0] off time (only valid when pwm bit = 0) replaces frq bits assumes 4-mhz clock tof2 tof1 tof0 off time default 0 0 0 20 s 0 0 1 24 s 0 1 0 28 s 0 1 1 32 s 1 0 0 36 s 1 0 1 40 s 1 1 0 44 sd 1 1 1 48 s frq[2..0] frequency (only valid when pwm bit = 1) replace tof bits assumes 4-mhz clock frq2 frq1 frq0 period / frequency default 0 0 0 24 s / 41.7 khz 0 0 1 32 s / 31.3 khz 0 1 0 40 s / 25.0 khz 0 1 1 46 s / 21.7 khz 1 0 0 52 s / 19.2 khz 1 0 1 56 s / 17.9 khz 1 1 0 60 s / 16.7 khz d 1 1 1 64 s / 15.6 khz pfd[2..0] fast decay time for mixed decay assumes 4-mhz clock pfd2 pfd1 pfd0 fast decay time default 000 2 s 001 3 s 010 4 s 011 6 s 100 8 sd 10110 s 11014 s 11120 s mxi[1..0] max phase current as a percentage of i smax mxi1 mxi0 maximum current default 0 0 25% 0 1 50% 1 0 75% 1 1 100% d ms[1..0] microstep mode for external step input control ms1 ms0 microstep mode default 0 0 full step d 0 1 half step 1 0 quarter step 1 1 sixteenth step tbk[1..0] blank time assumes 4-mhz clock tbk1 tbk0 blank time default 00 1 s 0 1 1.5 sd 1 0 2.5 s 1 1 3.5 s syr synchronous rectification syr synchronous rectification default 0 diode recirculation 1 synchronous d
automotive, programmable stepper driver a3981 18 allegro microsystems, llc 115 northeast cutoff worcester, massachusetts 01615-0036 u.s.a. 1.508.853.5000; www.allegromicro.com 1514131211109876543210 config 1 01 osc tsc1 tsc0 cd3 cd2 cd1 cd0 diag1 diag0 01000000100000 run 1 0 en ol1 ol0 hlr slew brk dcy1 dcy0 sc5 sc4 sc3 sc2 sc1 sc0 00101001000000 configuration register 1 run register sc[5..0] step change number 2?s complement format positive value increases step angle number negative value decreases step angle number dcy[1..0] decay mode selection dcy1 dcy0 decay mode default 0 0 slow 0 1 mixed?pfd fixed d 1 0 mixed?pfd auto 1 1 fast diag[1..0] selects signal routed to diag output diag1 diag0 signal on diag pin default 0 0 fault?low true d 0 1 st?low true 1 0 pwm-on, phase a 1 1 temperature tsc[1..0] overcurrent fault delay assumes 4-mhz clock tsc1 tsc0 detect delay time default 0 0 0.5 s 01 1 s 10 2 sd 11 3 s ol[1..0] open load current threshold as a percentage of maximum current defined by i smax and mxi[1..0] ol1 ol0 open load current default 0 0 20% 0 1 30% d 1 0 40% 1 1 50% cd[3..0] pwm count difference for st detection default to 8 osc selects clock source osc clock source default 0 internal d 1 external brk brake enable brk brake default 0 normal operation d 1 brake active slew slew rate control slew slew rate control default 0 disable 1 enable d hlr selects slow decay and brake recirculation path hlr recirculation path default 0 high side d 1 low side en phase current enable or with enable pin en phase current enable default 0 output bridges disabled if enable pin = 0 d 1 output bridges enabled
automotive, programmable stepper driver a3981 19 allegro microsystems, llc 115 northeast cutoff worcester, massachusetts 01615-0036 u.s.a. 1.508.853.5000; www.allegromicro.com ff fault register flag tw1 temperature diagnostic tw0 temperature diagnostic ov overvoltage on vbb detected uv undervoltage on vreg st stall detected olb open load detected on phase b ola open load detected on phase a bml overcurrent detected on bm output low side bmh overcurrent detected on bm output high side bpl overcurrent detected on bp output low side bph overcurrent detected on bp output high side aml overcurrent detected on am output low side amh overcurrent detected on am output high side apl overcurrent detected on ap output low side aph overcurrent detected on ap output high side 1514131211109876543210 tblld 1 1 ptp pt5 pt4 pt3 pt2 pt1 pt0 00000000100000 fault 0 ff tw1 tw0 ov uv st olb ola bml bmh bpl bph aml amh apl aph fault 1 ff tw1 tw0 ov uv st olb ola 0 0 sa5 sa4 sa3 sa2 sa1 sa0 table load register fault register 0 fault register 1 table load register mapping step angle number phase a phase b 0% 0 32 16 48 pt(0) 1 31 33 63 15 17 47 49 pt(1) 2 30 34 62 14 18 46 50 pt(2) 3 29 35 61 13 19 45 51 pt(3) 4 28 36 60 12 20 44 52 pt(4) 5 27 37 59 11 21 43 53 pt(5) 6 26 38 58 10 22 42 54 pt(6) 7 25 39 57 9 23 41 55 pt(7) 8 24 40 56 8 24 40 56 pt(8) 9 23 41 55 7 25 39 57 pt(9) 10 22 42 54 6 26 38 58 pt(10) 11 21 43 53 5 27 37 59 pt(11) 12 20 44 52 4 28 36 60 pt(12) 13 19 45 51 3 29 35 61 pt(13) 14 18 46 50 2 30 34 62 pt(14) 15 17 47 49 1 31 33 63 pt(15) 16 48 0 32 ff fault register flag tw1 temperature diagnostic tw0 temperature diagnostic ov overvoltage on vbb detected uv undervoltage on vreg or vbb detected st stall detected olb open load detected on phase b ola open load detected on phase a sa[0..5] step angle number read back ola open load detected on phase a tw[0..1] temperature diagnostic tw1 tw0 thermal indicator 0 0 no fault 0 1 cold warning 1 0 hot warning 1 1 overtemperature shutdown ptp parity bit (odd parity) pt(0..15)[5..0] phase table value
automotive, programmable stepper driver a3981 20 allegro microsystems, llc 115 northeast cutoff worcester, massachusetts 01615-0036 u.s.a. 1.508.853.5000; www.allegromicro.com motor movement control the a3981 provides two independent methods to control the movement of a stepper motor. the simpler is the step and direc- tion method, which only requires two control signals to control the stepper motor in either direction. the other method is through the serial interface, which provides more flexible control capa- bility. both methods can be used together (although it is not common), provided the timing restrictions of the step input in relation to the strn input are preserved. phase table and phase diagram the key to understanding both of the available control methods lies in understanding the phase current table (table 7). this table contains the relative phase current magnitude and direction for each of the two motor phases at each microstep position. the maximum resolution of the a3981 is one-sixteenth microstep. that is 16 microsteps per full step. there are 4 full steps per elec- trical cycle, so the phase current table has 64 microstep entries. the entries are numbered from 0 to 63. this number represents the phase angle within the full 360 electrical cycle and is called the step angle number. this is illustrated in figure 6. figure 6 shows the contents of the phase current table as a phase diagram. the phase b current, i b , from the phase current table, is plotted on horizontal axis and the phase a current, i a , is plotted on the vertical axis. the resultant motor current at each microstep is shown as numbered radial arrows. the number shown corre- sponds to the one-sixteenth microstep step angle number in the phase current table. figure 7 shows an example of calculating the resultant motor current magnitude and angle for step number 28. the target is to have the magnitude of the resultant motor current be 100% at all microstep positions. the relative phase currents from the phase current table are: i a = 37.50% i b = ?92.19% assuming a full scale (100%) current of 1a means that the two phase currents are: i a = 0.3750 a i b = -0.9219 a application information i a i b 0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 23 22 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 figure 6. a3981 phase current table as a phase diagram; values shown are referred to as the step angle number figure 7. calculation of resultant motor current i a 24 28 32 i b i a28 i b28 = ? 92.19% ? 28 = 157.9 =37.5% 31 30 29 27 26 25
automotive, programmable stepper driver a3981 21 allegro microsystems, llc 115 northeast cutoff worcester, massachusetts 01615-0036 u.s.a. 1.508.853.5000; www.allegromicro.com the magnitude of the resultant will be the square root of the sum of the squares of these two currents: 9953 (a) . 0 8499 . 0 1406 . 0 | | 2 2 28 ? ? ? ? ? b a i i i so the resultant current magnitude is 99.53% of full scale. this is within 0.5% of the target (100%) and is well within the 5% accuracy of the a3981. the reference angle, zero degrees (0), within the full electrical cycle (360), is defined as the angle where i b is at +100% and i a is zero. each full step is represented by 90 in the electrical cycle so each one-sixteenth microstep is: 90/16 steps = 5.625. the target angle of each microstep position with the electrical cycle is determined by the product of the step angle number and the angle for a single microstep. so for the example of figure 7: ? ? ? ? ? 5 . 157 625 . 5 28 ) ( 28 target a the actual angle is calculated using basic trigonometry as: ? ? ? ? ? ? ? ? ? ? ? 28 28 1 ) ( 28 tan 180 b a actual i i a ?? ? ? ? ? ? 9 . 157 1 . 22 180 so the angle error is only 0.4. equivalent to about 0.1% error in 360 and well within the current accuracy of the a3981. note that each phase current in the a3981 is defined by a 6-bit dac. this means that the smallest resolution of the dac is 100 / 64 = 1.56% of the full scale, so the a3981 cannot produce a resultant motor current of exactly 100% at each microstep. nor can it produce an exact microstep angle. however, as can be seen from the calculations above, the results for both are well within the specified accuracy of the a3981 current control. the resultant motor current angle and magnitude are also more than precise enough for all but the highest precision stepper motors. with the phase current table, control of a stepper motor is simply a matter of increasing or decreasing the step angle number to move around the phase diagram of figure 7. this can be in predefined multiples using the step input, or it can be variable using the serial interface. using step and direction control the step input moves the motor at the microstep resolution defined by the two microstep select variables, ms0 and ms1, logic levels. the dir input defines the motor direction. these inputs define the output of a translator which determines the required step angle number in the phase current table. the ms0 and ms1 can be set to select full step, half step, quarter step, or sixteenth step microstepping as follows: ms1 ms0 microstep mode 0 0 full step 0 1 half step 1 0 quarter step 1 1 sixteenth step ms0 and ms1 can be accessed through the serial interface or directly on pins 13 and 12 respectively. the values of ms0 and ms1 are defined as the logical or of the logic level on the input pins and the value in configuration register 0. the bits in the register default to 0 so if the serial interface is not used then ms0 and ms1 are defined by the input pins alone. if only the serial interface is used to set the microstep resolution, then the ms0 and ms1 logic input pins should be tied low to ensure that the register retains full control over all resolutions. note that the microstep select variables, ms0 and ms1, are only used with the step input; they can be ignored if the motor is fully controlled through the serial interface. in sixteenth step mode the translator simply increases or decreases the step angle number on each rising edge of the step input, depending on the logic state of the dir input. in the other three microstep resolution modes the translator outputs spe- cific step angle numbers as defined in the phase current table. full step uses four of the entries in the phase current table. these are 8, 24, 40, and 56 as shown in figure 8. note that the four posi- tions selected for full step are not the points at which only one current is active, as would be the case in a simple on-off full step driver. there are two advantages in using these positions rather than the single full current positions. with both phases active, the power dissipation is shared between two drivers. this slightly improves the ability to dissipate the heat generated and reduces the stress on each driver. the second reason is that the holding torque is slightly improved because the forces holding the motor are mainly rotational rather than mainly radial. half step uses eight of the entries in the phase current table. these are 0, 8, 16, 24, 32, 40, 48, and 56 as shown in figure 9. quarter step uses sixteen of the entries in the phase current table. these are 0, 4, 8, 12, 16, 20, 24, 28, 32, 36, 40, 44, 48, 52, 56, and 60 as shown in figure 10.
automotive, programmable stepper driver a3981 22 allegro microsystems, llc 115 northeast cutoff worcester, massachusetts 01615-0036 u.s.a. 1.508.853.5000; www.allegromicro.com in half step and in quarter step, the single phase active positions are used to preserve symmetry. however, if the motor is required to stop with a significant holding torque for any length of time it is recommended that the 45 positions be used; those are step angle numbers 8, 24, 40, and 56, as used with full-step resolu- tion. the following table summarizes the step angle numbers used for the four resolutions available when using the step input to control the output of the a3981: mode step angle numbers used full 8, 24, 40, 56 half 0, 8, 16, 24, 32, 40, 48, 56 quarter 0, 4, 8, 12, 16, 20, 24, 28, 32, 36, 40, 44, 48, 52, 56, 60 sixteenth all the microstep select inputs can be changed between each rising edge of the step input. the only restriction is that the mso and ms1 logic inputs must comply with the set-up and hold timing constraints. when the microstep resolution changes, the a3981 moves to the next available step angle number on the next rising edge of the step input. for example, if the microstep mode is sixteenth and the present step angle number is 59, then with the direction forwards (increasing step angle number), changing to quarter step mode will cause the phase number to go to 60 on the next rising edge of the step input. if instead the microstep mode is changed to half step then the phase number will go to 0 on the next rising edge of the step input. if the microstep mode is changed to full step then the phase number will go to 8 on the next rising edge of the step input. control through the serial interface the a3981 provides the ability to directly control the motor movement using only the serial interface. in fact, all features of the a3981, except sleep mode, can be controlled through the serial interface thus removing the requirement for individual control inputs. this can reduce the interface requirement from multiple i/o signals to a single four wire interface. motor movement is controlled using the serial interface by increasing or decreasing the step angle number. note that the maximum value of the step angle number is 63 and the mini- mum number is 0.therefore, any increase or decrease in the microstep number is performed using modulo 64 arithmetic. this means that increasing a step angle number of 63 by 1 will pro- duce a step angle number of 0. increasing by two from 63 will produce 1 and so on. similarly in the reverse direction, decreasing a step angle number of 0 by 1 will produce a step angle num- ber of 63. decreasing by two from 0 will produce 62 and so on. the least significant six bits of the run register, bits 0 to 5, are the step change number, sc[5..0]. this number is a two?s comple- ment number that is added to the step angle number causing it to increase or decrease. two?s complement is the natural integer number system for most microcontrollers. this allows standard i a 0 4 8 12 16 20 24 28 i b 32 36 40 44 48 52 56 60 0 8 16 24 32 40 48 56 i b i a 8 24 40 56 i b i a figure 8. full-step phase diagram using step input figure 9. half-step phase diagram using step input figure 10. quarter-step phase diagram using step input
automotive, programmable stepper driver a3981 23 allegro microsystems, llc 115 northeast cutoff worcester, massachusetts 01615-0036 u.s.a. 1.508.853.5000; www.allegromicro.com arithmetic operators to be used, within the microcontroller, to determine the size of the next step increment. table 6 shows the binary equivalent of each decimal number between ?16 and +16. each increase in the step angle number represents a forwards movement of one-sixteenth microstep. each decrease in the step angle number represents a reverse movement of one-sixteenth microstep. to move the motor one full step, the step angle number must be increased or decreased by 16. to move the motor one half step, the step angle number must be increased or decreased by 8. for quarter step the increase or decrease is 4 and for eighth step, 2. so, for example, to continuously move the motor forwards in quarter-step increments, the number 4 (000100) is repeatedly written to sc[5..0] through the serial interface run register (see figure 11). to move the motor backwards in quarter step incre- ments, the number -4 ( 111100) is repeatedly written to sc[5..0] (see figure 12). the remaining bits in the run register should be set for the required configuration and sent with the step change number each time. the step rate is controlled by the timing of the serial interface. it is the inverse of the step time, t step , shown in figure 11. the motor step only takes place when the strn goes from low to table 6. binary equivalents decimal 2?s complement decimal 2?s complement 0 000000 1 000001 ?1 111111 2 000010 ?2 111110 3 000011 ?3 111101 4 000100 ?4 111100 5 000101 ?5 111011 6 000110 ?6 111010 7 000111 ?7 111001 8 001000 ?8 111000 9 001001 ?9 110111 10 001010 ?10 110110 11 001011 ?11 110101 12 001100 ?12 110100 13 001101 ?13 110011 14 001110 ?14 110010 15 001111 ?15 1 10001 16 010000 ?16 110000 sdi sck strn 1 0 1 0 1 0 1 0 1 0 1 1 1 1 0 0 -4 sdi sck strn 1 0 1 0 1 0 1 0 1 0 0 0 0 1 0 0 +4 t step figure 11. serial interface sequence for quarter step in forward direction figure 12. serial interface sequence for quarter step in reverse direction
automotive, programmable stepper driver a3981 24 allegro microsystems, llc 115 northeast cutoff worcester, massachusetts 01615-0036 u.s.a. 1.508.853.5000; www.allegromicro.com high when writing to the run register. the motor step rate is therefore determined by the timing of the rising edge of the strn input. the clock rate of the serial interface, defined by the fre- quency of the sck input, has no effect on the step rate. using the phase table load capability torque ripple reduction the performance and audible noise of any motor drive system is defined, to a large extent, by the torque ripple generated by both the motor and the load. in most cases, when using a stepper motor as the mechanical drive, the torque ripple of the load is not related to the mechanical steps of the motor and must be reduced by means unrelated to the motor and its drive system. however, for stepper motors in particular, torque ripple produced by the motor can be reduced by improvements in the mechanical design of the motor and by improvements in the phase current control system. torque ripple will naturally be high when driving a stepper motor in full step mode, due to the nature of stepping. however the torque ripple can be reduced by using microstepping. increas- ing the number of microsteps per mechanical step will result in reduced torque ripple. this is one of the major reasons for using microstepping. in the majority of cases the standard sinusoidal, microstep current profile will be sufficient to achieve a good performance with a good quality motor. in a few cases, further improvements in torque ripple performance may be achieved by modifying the microstep current profile to more closely match the motor charac- teristics. this is usually only necessary for higher quality, higher power stepper motors. when using microstepping, the torque ripple is defined by the variation in torque at each microstep. in a hybrid stepper motor this is mostly determined by the mechanical construction of the motor, particularly the shape of the teeth on the poles of the sta- tor. the shape of these teeth determine the variation in the torque constant , the ratio between current and torque, as the motor rotates. the variation in the torque constant can be seen by mea- suring the back emf of the motor when being driven as a genera- tor, that is when the shaft is driven by external means and the phase voltage is monitored. the back emf represents the motor constant, which is essentially proportional to the torque constant. if such torque ripple reduction measures are required, the a3981 provides the ability to modify the microstep current profile by programming the internal phase current table through the serial interface. the modified profile is then used, in place of the default sinusoidal profile, to compensate for any variation in motor torque constant. the current at each step angle number can be set to suit the microstep current profile requirements of a specific motor. note: this is an advanced feature of the a3981, which will not be required for most applications. in general the default sinusoidal profile will suffice and therefore the phase current table does not have to be loaded. loading the phase current table the full phase current table in the a3981 contains one 6-bit value for each phase, at each microstep position. with 16 microsteps per mechanical step, 4 mechanical steps per electrical cycle, and 2 phases this gives a total of 128 values. however, due to symme- try, described below, this reduces to 17 independent values, one of which is always zero. the remaining 16 values can be loaded sequentially through the serial interface using the phase table load register. figure 13 shows the default phase table values plotted by step angle number. similar information is provided in table 7. the diagram in figure 13 is marked with four quadrants, q1 to q4. the set of phase table values is the same in each quadrant in each phase. consider phase a (bottom graph), quadrant 1 (q1). this contains step angle numbers 0 to 15. the default values in these 16 positions are selected to produce one quarter of a sinusoid. now consider the next quadrant (q2) of phase a. the sequence of values in this quadrant form a mirror image, by step angle number, of the values in q1 so the same values are used but entered in the reverse sequence. the following table shows the step angle number in the first row increasing from 0 to 15, from left to right, and the default values also increasing from left to right in the second row. these first two rows are the entries for q1 of phase a. step 0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 q1 value 0 5 11 18 23 29 35 40 44 48 52 55 58 60 62 63 step 31 30 29 28 27 26 25 24 23 22 21 20 19 18 17 16 q2 value 5 11 18 23 29 35 40 44 48 52 55 58 60 62 63 63 the second two rows are the entries for q2 of phase a. the step angle number in the third row increases from 16 to 31, this time from right to left, but the same default values still increase from left to right. a single value is therefore placed in more than one location in the table. shown outlined above, steps 4 and 28 both contain the value 23. the same principal can be applied to q3 and q4 of phase a. in this case the mirror image is in the horizontal axis, about the zero
automotive, programmable stepper driver a3981 25 allegro microsystems, llc 115 northeast cutoff worcester, massachusetts 01615-0036 u.s.a. 1.508.853.5000; www.allegromicro.com (dac value) 0 2 3 4 5 6 7 8 9 14 15 16 17 18 19 20 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 1 21 11 10 13 12 48 q1 q2 q3 q4 q1 q2 q3 q4 i b (forwards) 63 6 2 58 5 2 44 35 2 3 11 11 2 3 35 44 5 2 58 6 2 63 5 1 8 2 9 4 0 4 8 55 60 5 1 8 2 9 4 0 4 8 55 60 63 6 2 58 5 2 44 3 5 2 3 11 11 2 3 35 44 5 2 58 6 2 63 5 1 8 2 9 4 0 4 8 55 60 5 1 8 2 9 4 0 4 8 55 60 i b (reverse) i a (forwards) i a (reverse) figure 13. default phase table values step angle number (dac value) (dac value) (dac value)
automotive, programmable stepper driver a3981 26 allegro microsystems, llc 115 northeast cutoff worcester, massachusetts 01615-0036 u.s.a. 1.508.853.5000; www.allegromicro.com table 7. phase current table (default, power-on content) step angle number phase current (% of i pmax ) step angle phase dac step angle number phase current (% of i pmax ) step angle phase dac full 1/2 1/4 1/8 1/16 a b a b a b full 1/2 1/4 1/8 1/16 a b a b a b 0 0 0 0 0.00 100.00 0.0 0 0 0 63 4 8 16 32 0.00 -100.00 180.0 0 1 0 63 1 9.38 100.00 5.4 0 0 5 63 33 -9.38 -100.00 185.4 1 1 5 63 1 2 18.75 98.44 10.8 0 0 11 62 17 34 -18.75 -98.44 190.8 1 1 11 62 3 29.69 95.31 17.3 0 0 18 60 35 -29.69 -95.31 197.3 1 1 18 60 1 2 4 37.50 92.19 22.1 0 0 23 58 9 18 36 -37.50 -92.19 202.1 1 1 23 58 5 46.88 87.50 28.2 0 0 29 55 37 -46.88 -87.50 208.2 1 1 29 55 3 6 56.25 82.81 34.2 0 0 35 52 19 38 -56.25 -82.81 214.2 1 1 35 52 7 64.06 76.56 39.9 0 0 40 48 39 -64.06 -76.56 219.9 1 1 40 48 0 1 2 4 8 70.31 70.31 45.0 0 0 44 44 2 5 10 20 40 -70.31 -70.31 225.0 1 1 44 44 9 76.56 64.06 50.1 0 0 48 40 41 -76.56 -64.06 230.1 1 1 48 40 5 10 82.81 56.25 55.8 0 0 52 35 21 42 -82.81 -56.25 235.8 1 1 52 35 11 87.50 46.88 61.8 0 0 55 29 43 -87.50 -46.88 241.8 1 1 55 29 3 6 12 92.19 37.50 67.9 0 0 58 23 11 22 44 -92.19 -37.50 247.9 1 1 58 23 13 95.31 29.69 72.7 0 0 60 18 45 -95.31 -29.69 252.7 1 1 60 18 7 14 98.44 18.75 79.2 0 0 62 11 23 46 -98.44 -18.75 259.2 1 1 62 11 15 100.00 9.38 84.6 0 0 63 5 47 -100.00 -9.38 264.6 1 1 63 5 2 4 8 16 100.00 0.00 90.0 0 0 63 0 6 12 24 48 -100.00 0.00 270.0 1 1 63 0 17 100.00 -9.38 95.4 0 1 63 5 49 -100.00 9.38 275.4 1 0 63 5 9 18 98.44 -18.75 100.8 0 1 62 11 25 50 -98.44 18.75 280.8 1 0 62 11 19 95.31 -29.69 107.3 0 1 60 18 51 -95.31 29.69 287.3 1 0 60 18 5 10 20 92.19 -37.50 112.1 0 1 58 23 13 26 52 -92.19 37.50 292.1 1 0 58 23 21 87.50 -46.88 118.2 0 1 55 29 53 -87.50 46.88 298.2 1 0 55 29 11 22 82.81 -56.25 124.2 0 1 52 35 27 54 -82.81 56.25 304.2 1 0 52 35 23 76.56 -64.06 129.9 0 1 48 40 55 -76.56 64.06 309.9 1 0 48 40 1 3 6 12 24 70.31 -70.31 135.0 0 1 44 44 3 7 14 28 56 -70.31 70.31 315.0 1 0 44 44 25 64.06 -76.56 140.1 0 1 40 48 57 -64.06 76.56 320.1 1 0 40 48 13 26 56.25 -82.81 145.8 0 1 35 52 29 58 -56.25 82.81 325.8 1 0 35 52 27 46.88 -87.50 151.8 0 1 29 55 59 -46.88 87.50 331.8 1 0 29 55 7 14 28 37.50 -92.19 157.9 0 1 23 58 15 30 60 -37.50 92.19 337.9 1 0 23 58 29 29.69 -95.31 162.7 0 1 18 60 61 -29.69 95.31 342.7 1 0 18 60 15 30 18.75 -98.44 169.2 0 1 11 62 31 62 -18.75 98.44 349.2 1 0 11 62 31 9.38 -100.00 174.6 0 1 5 63 63 -9.38 100.00 354.6 1 0 5 63 4 8 16 32 0.00 -100.00 180.0 0 1 0 63 0000 0.00 100.00 0.0 0 0 0 63 reference value. although the current in q3 and q4 for phase a is effectively negative, the negation is provided by controlling the direction of the current. the current control scheme still operates using positive values. as shown below, the table of values can be extended to include q3 and q4 with the current direction indicated in the last column. note that the same value is now applied to four locations in the full 360-degree electrical cycle. step 0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 q1 fwd value 0 5 11 18 23 29 35 40 44 48 52 55 58 60 62 63 step 31 30 29 28 27 26 25 24 23 22 21 20 19 18 17 16 q2 fwd value 5 11 18 23 29 35 40 44 48 52 55 58 60 62 63 63 step 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 q3 rev value 0 5 11 18 23 29 35 40 44 48 52 55 58 60 62 63 step 63 62 61 60 59 58 57 56 55 54 53 52 51 50 49 48 q4 rev value 5 11 18 23 29 35 40 44 48 52 55 58 60 62 63 63 shown outlined above, steps 4, 28, 36, and 60 all contain the value 23. the other phase, phase b, uses the same values as phase a but shifted back by 16 step angle numbers. the full distribution of the value entered in step 4 of phase a is highlighted in figure 13 (and shown in table 7). this single value is used in a total of eight locations. the same distribution of values applies to all the values in steps 1 to 15. these values are defined in the a3981 as pt(0) to pt(14), respectively. there are two exceptions to this data distribution principal. these are the zero value and the maximum value: ? the values in phase a steps 0 and 32 and phase b steps 16 and 48 are always set to zero and cannot be programmed. ? the maximum value, pt(15), is distributed to only two step angle numbers in each phase. these are the points in the cycle where the peak current is required, namely phase a steps 16 and 48 and phase b steps 0 and 32.
automotive, programmable stepper driver a3981 27 allegro microsystems, llc 115 northeast cutoff worcester, massachusetts 01615-0036 u.s.a. 1.508.853.5000; www.allegromicro.com each of the 16 values written to the phase table is a 6-bit num- ber that determines the current trip point for the associated step. the highest value, 63, represents the maximum phase current, i pmax , defined in the section of the specification on phase cur- rent control. other numbers represent a percentage of i pmax . for example, the number 23 sets the phase current trip point to 23/63 = 36.51% of i pmax . there are two restrictions when using the phase table load capa- bility: ? the required current profile must conform to the symmetry shown in figure 14. the forward (positive) current part must be symmetrical about step angle number16 for phase a and about 0 for phase b. the reverse (negative) current part must be sym- metrical about step angle number 48 for phase a and about 32 for phase b. the forward and reverse profiles for each phase must be the same. ? the phase current must be zero at step angle numbers 0 and 32 for phase a and step angle numbers 16 and 48 for phase b. phase current table programming example as an example of programming the phase current table, consider the current profile shown in figure 14. this shows a profile where the torque from each phase is required to be relatively higher at the detent points, that is, the points where only one phase is active. (this current profile does not relate to any specific motor, it is only shown as an example.) figure 14 shows the required current for each phase at each step angle number as a percentage of the maximum phase current, i pmax , defined above. the waveform conforms to the required symmetry and zero crossing restrictions, so the profile for phase a for step angle numbers from 0 to 16 (outlined and shaded) can be used to determine the phase table contents. the first step is to digitize the profile into microsteps and the percentage values into 6-bit numbers, as shown in figure 15. at each of the one-sixteenth microsteps, identified by step angle number, the value of the phase current, as a percentage of the maximum phase current, i pmax , is digitized to a 6-bit value from 0 to 63. the value 63 represents 100% of i pmax , 32 represents figure 14. example current profile phase current table value figure 15. digitizing the example current profile
automotive, programmable stepper driver a3981 28 allegro microsystems, llc 115 northeast cutoff worcester, massachusetts 01615-0036 u.s.a. 1.508.853.5000; www.allegromicro.com 32/63=50.8% and so on. the value at each step angle number is then assigned to its corresponding phase table values as follows: ?? n di n pt ? ? 1 where di n represents the digitized value of the current at step angle number n. a selection of the values and the corresponding phase current table entries is shown in figure15. the full set of phase current table values is shown in the table below. step 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 value 10 20 25 28 29 30 31 32 35 40 50 58 60 62 63 63 pt 0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 these 16 values are then loaded sequentially into the phase current table through the phase table load register of the serial interface. each value is then distributed to the appropriate step angle numbers as described above and as shown in table 4c in the phase table load register section. a representation of the final result is shown in figure 16. this is the digitized version of the required current profile shown in figure 14. figure 16. resulting example current profile
automotive, programmable stepper driver a3981 29 allegro microsystems, llc 115 northeast cutoff worcester, massachusetts 01615-0036 u.s.a. 1.508.853.5000; www.allegromicro.com power dissipation the a3981 is a power circuit, therefore careful consideration must be given to power dissipation and the effects of high cur- rents on interconnect and supply wiring. a first order approximation of the power dissipation in the a3981 can be determined by examining the power dissipation in each of the two bridges during each of the operation modes. when syn- chronous rectification is used current will flow most of the time through the dmos transistors that are switched on. when syn- chronous rectification is not used the current will flow through the body diode of the dmos transistors during the decay phase. the use of fast or slow decay will also affect the dissipation. all the above combinations can be calculated from five basic dmos output states as shown in figure 17. figure 17. basic output states ? diagonally opposite dmos output transistors are on ? current flows from ground through load to positive supply dissipation is i 2 r losses in the dmos transistors: p d(sf) = i 2 (r ds(on)h +r ds(on)l ) ? both low-side dmos output transistors are on ? current circulates through both transistors and the load dissipation is i 2 r losses in the dmos transistors: p d(ss) = i 2 (2 r ds(on)l ) ? diagonally opposite body diodes conducting ? current flows from ground through load to positive supply dissipation is iv losses in the diodes: p d(nf) = i ( v fh + v fl ) ? one low-side dmos output transistor and one body diode conducting ? current circulates through the diode, the transistor and the load dissipation is i 2 r losses in the dmos transistors plus iv loss in the diode: p d(ns) = (i 2 r ds(on)l ) ( i v f ) (used in all combinations) ? diagonally opposite dmos output transistors are on ? current flows from positive supply through load to ground dissipation is i 2 r losses in the dmos transistors: p d = i 2 (r ds(on)h + r ds(on)l ) synchronous fast decay non-synchronous fast decay synchronous slow decay non-synchronous slow decay drive current ramp-up
automotive, programmable stepper driver a3981 30 allegro microsystems, llc 115 northeast cutoff worcester, massachusetts 01615-0036 u.s.a. 1.508.853.5000; www.allegromicro.com the total power dissipation for each of the four decay modes, p d(tot) xx , is the average power for the drive current ramp por- tion, p d , and the drive current decay portion, p d(xx) of the pwm cycle. for slow decay the current will be rising for approximately 20% of the cycle and decaying for approximately 80%. for fast decay the ratio will be approximately 50%. note that these are approximate figures and will vary slightly depending on the motor characteristics and the use of synchronous rectification. the following formulas may be used to estimate total power dis- sipation: ? synchronous slow decay mode p d(tot)ss = 0.2 p d + 0.8 p d(ss) p d(tot)ss = 0.2 ( i 2 [ r ds(on)h + r ds(on)l ]) + 0.8 ( i 2 2 r ds(on)l ) ? non-synchronous slow decay mode p d(tot)ns = 0.2 p d + 0.8 p d(ns) p d(tot)ns = 0.2 ( i 2 [ r ds(on)h + r ds(on)l ]) + 0.8 ( i 2 r ds(on)l + i v f ) ? synchronous fast decay mode p d(tot)sf = 0.5 p d + 0.5 p d(sf) p d(tot)sf = i 2 ( r ds(on)h + r ds(on)l ) ? non-synchronous fast decay mode p d(tot)nf = 0.5 p d + 0.5 p d(nf) p d(tot)nf = 0.5( i 2 [r ds(on)h + r ds(on)l ] ) + 0.5( i [ v fh + v fl ] ) an approximation of the total dissipation can be calculated by summing the total power dissipated in both bridges and adding the control circuit power due to v bb i bb and v dd i dd . the total power at the required ambient temperature can then be compared to the allowable power dissipation shown in figure 18. for critical applications, where the first order power estimate is close to the allowable dissipation, the power calculation should take several other parameters into account including: motor parameters, dead time, and switching losses in the controller. ambient temperature (c) allowable power dissipation (w) 150 125 100 75 50 25 5 4 3 2 1 0 r ja = 28 c/w (on 4-layer pcb) r ja = 32 c/w (on 2-layer pcb) figure 18. allowable power dissipation, on typical pcbs
automotive, programmable stepper driver a3981 31 allegro microsystems, llc 115 northeast cutoff worcester, massachusetts 01615-0036 u.s.a. 1.508.853.5000; www.allegromicro.com layout traces pcb the printed circuit board (pcb, or printed wiring board) should use a higher weight copper thickness than a standard small signal or digital circuit board. this helps to reduce the impedance of the printed traces when conducting high currents. pcb traces carrying switching currents should be as wide and short as pos- sible to reduce the inductance of the trace. this will help reduce any voltage transients caused by current switching during pwm current control. for optimum thermal performance, the exposed thermal pad on the underside of the a3981 should be soldered directly onto the board. a solid ground plane should be added to the opposite side of the board, and multiple vias through the board to the ground plane should be placed in the area under the thermal pad. decoupling all supplies should be decoupled with an electrolytic capacitor in parallel with a ceramic capacitor. the ceramic capacitor should have a value of 100 nf and should be placed as close as pos- sible to the associated supply and ground pins of the a3981. the electrolytic capacitor connected to vbb should be rated at least 1.5 times the maximum circuit voltage, and selected to support the maximum ripple current provided to the motor. the value of the capacitor is unimportant but should be the lowest value with the necessary ripple current capability. the pump capacitor between cp1 and cp2, the pump storage capacitor between vcp and vbb, and the compensation capaci- tor between vreg and ground should be connected as close as possible to the respective pins of the a3981. grounding a star ground system, with the common star point located close to the a3981, is recommended. the reference ground, agnd (pin 7), and the power ground, pgnd (pin 21), must be connected together externally. the copper ground plane located under the exposed thermal pad is typically used as the star ground point. current sense resistor in sensing the output current level, to minimize inaccuracies caused by ground-trace ir drops, the current sense resistor (r s ) should have an independent ground return to the star ground point. this path should be as short as possible. for low-value sense resistors, the ir drop in the pcb trace to the sense resis- tor can be significant and should be taken into account. surface mount chip resistors are recommended to minimize contact resistance and parasitic inductance. the value, r s , of the sense resistor is given by: smax ref s i v r ? ? 16 there is no restriction on the value of r s or v ref , other than the range of v ref over which the output current precision is guaran- teed. however, it is recommended that the value of v ref be kept as high as possible to improve the current accuracy. the table below provides increasing values of i smax for suggested values of v ref and standard e96 values of r s . suggested values i smax (ma) r s (m ) v ref (v) 100 499 0.8 200 499 1.6 300 417 2.0 405 309 2.0 501 249 2.0 610 205 2.0 702 178 2.0 812 154 2.0 912 137 2.0 1008 124 2.0
automotive, programmable stepper driver a3981 32 allegro microsystems, llc 115 northeast cutoff worcester, massachusetts 01615-0036 u.s.a. 1.508.853.5000; www.allegromicro.com input/output structures dir step ms1 ms0 2 k 8v 6v vdd 47 k 1pf osc 8v 6v vdd 6v en 8v 6v vdd 1pf strn sc k sdi 8v 6v vdd sdo 8v vdd oap oam obp obm vbb vcp vbb 1 8 v 18v 14v vdd 8v cp1 cp2 vreg 8v 7.5v agnd pgnd ref 5 k 8v 6v 6v resetn 8v 6v vdd 1pf 50 k 6v diag 6v vdd 8v sens a sensb 22v vreg 2 k 25 25 2 k 51 k 51 k 500 120 figure 19a. supplies and reference figure 19b. sense inputs figure 19e. strn, sck, sdi inputs figure 19h. sdo output figure 19c. dir, step, ms1, ms0 inputs figure 19f. osc input figure 19i. phase outputs figure 19d. en input figure 19g. resetn input figure 19j. diag output
automotive, programmable stepper driver a3981 33 allegro microsystems, llc 115 northeast cutoff worcester, massachusetts 01615-0036 u.s.a. 1.508.853.5000; www.allegromicro.com pin-out diagram terminal list table name number description agnd 7 analog reference ground cp1 23 charge pump capacitor terminal cp2 24 charge pump capacitor terminal diag 16 diagnostic output dir 3 direction select input enable 26 bridge enable input ms0 13 microstep select input ms1 12 microstep select input oam 25 bridge a negative output oap 4 bridge a positive output obm 18 bridge b negative output obp 11 bridge b positive output osc 5 oscillator input pad ? connect exposed tab to ground name number description pgnd 21 power ground ref 8 reference input voltage resetn 27 chip reset sck 9 serial data clock sdi 6 serial data input sdo 17 serial data output sensa 1 current sense node ? bridge a sensb 14 current sense node ? bridge b step 19 step input strn 2 serial data strobe vbba 28 motor supply ? bridge a vbbb 15 motor supply ? bridge b vcp 22 above supply voltage vdd 10 logic supply vreg 20 regulated voltage 28 27 26 25 24 23 22 21 20 19 18 17 16 15 1 2 3 4 5 6 7 8 9 10 11 12 13 14 i/o & control timer reg ref vdd sensa strn dir oap agnd ref vdd obp sensb vbba resetn enable oam vcp pgnd vreg step obm diag vbbb 2 p c c s o sdi sck cp1 ms1 ms0 sdo charge pump
automotive, programmable stepper driver a3981 34 allegro microsystems, llc 115 northeast cutoff worcester, massachusetts 01615-0036 u.s.a. 1.508.853.5000; www.allegromicro.com package lp, 28-pin tssop with exposed thermal pad a 1.20 max 0.15 0.00 0.30 0.19 0.20 0.09 8o 0o 0.60 0.15 1.00 ref c seating plane c 0.10 28x 0.65 bsc 0.25 bsc 2 1 28 9.700.10 4.400.10 6.400.20 gauge plane seating plane a terminal #1 mark area b for reference only; not for tooling use (reference mo-153 aet) dimensions in millimeters dimensions exclusive of mold flash, gate burrs, and dambar protrusions exact case and lead configuration at supplier discretion within limits shown b c exposed thermal pad (bottom surface); dimensions may vary with device branded face 6.10 0.65 0.45 1.65 3.00 5.00 28 2 1 pcb layout reference view c 5.08 nom 3 nom reference land pattern layout (reference ipc7351 sop65p640x120-29cm); all pads a minimum of 0.20 mm from all adjacent pads; adjust as necessary to meet application process requirements and pcb layout tolerances; when mounting on a multilayer pcb, thermal vias at the exposed thermal pad land can improve thermal dissipation (reference eia/jedec standard jesd51-5)
automotive, programmable stepper driver a3981 35 allegro microsystems, llc 115 northeast cutoff worcester, massachusetts 01615-0036 u.s.a. 1.508.853.5000; www.allegromicro.com appendix a. driving a stepper motor a stepper motor is a particular form of brushless dc motor. as for any electric motor, motion is created by magnetic interaction between the stationary part of the motor, known as the stator, and the moving part of the motor, known as the rotor. the information presented here concentrates on a specific type of motor known as a hybrid stepper motor. this is the most common type of small stepper motor. it uses permanent magnets in the rotor to produce one set of constant magnetic fields and electromagnets in the stator to produce another set of varying magnetic fields. the term hybrid relates to the use of both electromagnets and permanent magnets. comparing bipolar and unipolar motors there are two options in small hybrid stepper motor construction. in the first, known as a unipolar stepper motor, there are indepen- dent electromagnets to generate each magnetic polarity, so two electromagnets are required per phase. each of these is energized with current in only one direction, producing a single magnetic field direction (unipolar). because the current in each electromag- net only flows in a single fixed direction, the control circuit can be very simple. the drawback is that only one electromagnet per phase can be energized at any time so, at most, only half of the motor volume is ever used to create torque on the rotor. a bipolar motor, in contrast, uses each electromagnet to pro- duce two opposing fields (bipolar) at different times, by allow- ing the current to flow in both directions. this means that the motor volume required for a bipolar motor is half of the volume required for a unipolar motor for the same torque output. the minor drawback is that a bipolar motor requires a more complex drive circuit in order to reverse the forcing voltage across the coil of the electromagnet. however, if the drive circuit is integrated into a single ic then the drive becomes cost effective. this, along with the improvement in torque output makes the bipolar motor a better solution for applications where the volume available is restricted. for this reason the following information will relate only to bipolar motors. in order to create continuous motion in one direction it is neces- sary to have two or more sets of electromagnets, that is, two or more phases. the simplest and most cost effective configuration for a stepper motor is to have two phases. for some applications that require an extremely low torque ripple, 3 phase, 5 phase, and even 9 phase stepper motors are sometimes used. however, the remainder of the information presented here relates specifically to 2-phase bipolar motors. moving a 2-phase bipolar stepper motor figure a1 shows the four possible current combinations in two phase windings, a and b, and the effect on a simplified repre- sentation of part of a stepper motor. in each case the stator with the electromagnets is shown at the top of the diagram and the rotor with the permanent magnets is shown at the bottom of the diagram. in figure a1 the stator consists of alternate phase a and phase b electromagnets. the winding direction of the electromagnet changes for each sequential electromagnet in each phase as indi- cated by the overbar above the phase letter and identified below as a-bar and b-bar . the result is that the magnetic poles will alternate for each sequential electromagnet of each phase. that means, for example, when the a electromagnet produces a north (n) magnetic pole at the end nearest to the rotor, then the a-bar electromagnet will produce a south (s) magnetic pole at the end nearest to the rotor. the windings for all the a and a-bar electromagnets are con- nected in series and driven by a single full bridge. similarly the windings for all the b and b-bar electromagnets are connected in series and driven by another single full bridge. so a 2-phase bipolar stepper motor requires two full bridges for full control. the rotor is much simpler than the stator, and consists of a solid base holding permanent magnets with alternating pole directions. there are no windings on the rotor, so there is no requirement to conduct current to the moving part of the motor. in addition the lack of current and windings means that there is no heat generated in the rotor, making cooling of the moving parts much simpler. the diagrams in figure a1 provide a representation of a small section of the mechanics of the motor. in practice the motor struc- ture is a little different from this, but the principle of operation is the same. starting at the top, panel (a) in figure a1, the current is flowing down through the phase a winding from top to bottom and there is no current in phase b. the result is an n magnetic pole on the a electromagnets and an s pole on the a-bar electromagnets. the rotor position is such that that the poles of the permanent magnets align with the poles of the electromagnets, n to s.
automotive, programmable stepper driver a3981 36 allegro microsystems, llc 115 northeast cutoff worcester, massachusetts 01615-0036 u.s.a. 1.508.853.5000; www.allegromicro.com a s _ a n b _ b a s _ a n b _ b stator s n n s s n n s n s rotor b a a _ a b n _ b s a _ a b n _ b s stator s n n s s n n s n s rotor ab n s a n _ a s b _ b a n _ a s b _ b stator n s s n n s s n rotor b a a _ a b s _ b n a _ a b s _ b n n s s n n s s n s n stator rotor ab figure a1. basic principle of bipolar stepper motor operation (a) ? phase a energized in positive direction ? phase b not energized permanent magnet poles on the rotor aligned with electromagnet poles on the stator (b) ? phase a not energized ? phase b energized in positive direction rotor moves to the right to realign permanent magnet poles on the rotor to the electromagnet poles on the stator. (c) ? phase a energized in negative direction. ? phase b not energized rotor moves to the right to realign permanent magnet poles on the rotor to the electromagnet poles on the stator. (d) ? phase a not energized. ? phase b energized in negative direction rotor moves to the right to realign permanent magnet poles on the rotor to the electromagnet poles on the stator.
automotive, programmable stepper driver a3981 37 allegro microsystems, llc 115 northeast cutoff worcester, massachusetts 01615-0036 u.s.a. 1.508.853.5000; www.allegromicro.com figure a2. half step operation in the next panel, panel (b), the current is flowing down through the phase b winding from top to bottom and there is no current in phase a. the result is an n pole on the b electromagnets and an s pole on the b-bar electromagnets. these magnetic poles will attract and repel the permanent magnets on the rotor producing a force that moves the rotor from left to right in the diagram until the poles of the permanent magnets again align with the poles of the electromagnets. in panel (c), the current is flowing up through the phase a wind- ing from bottom to top and there is no current in phase b. this reverses the pole orientation from the top panel, such that there is an s pole on the a electromagnets and an n pole on the a-bar electromagnets. as before, these magnetic poles will attract and repel the permanent magnets on the rotor producing a force that moves the rotor from left to right in the diagram, until poles of the permanent magnets again align with the poles of the electro- magnets. the bottom panel, panel (d), shows the final combination with current flowing up through the phase b winding from bottom to top and there is no current in phase a. this produces an n pole on the b electromagnets and a s pole on the b-bar electromag- nets. as before, these magnetic poles will attract and repel the permanent magnets on the rotor producing a force that moves the rotor from left to right until poles of the permanent magnets again align with the poles of the electromagnets. each of the four steps in figure a1 represents a single full mechanical step of the stepper motor. the four steps together represent a single electrical cycle. the step resolution depends entirely on the mechanical construc- tion of the motor and typically there will be 200 or more full steps per mechanical revolution of the motor. a 200-step motor will provide a resolution of 360 / 200 = 1.8 of rotation per step. stepping in the opposite direction to that described above is sim- ply a case of changing the step sequence or inverting one of the phase current directions. microstepping in many applications it is necessary to improve the resolution of the stepper motor, for more precise positioning control, or simply to increase the number of steps per revolution to reduce the torque ripple and therefore the vibration and noise of the motor. fortunately this can be achieved by driving both phases at the same time in order to move the rotor to a position between two electromagnets. this is known generically as microstepping. figure a2 shows the basic principle of microstepping. panels (a) and (c) of figure a2 correspond to panels (a) and (b) of figure a1. panel (b) shows each phase energized such that there are now two adjacent n poles and two adjacent s poles. in this example the currents in both phases is the same, and so the s and n poles of the rotor now move to half way between the positions in diagrams (a) and (c). figure a2 only shows a single mechanical step in total, which is one quarter of a full electrical cycle. this sequence is the lowest resolution form of microstepping, known as half step , and is the simplest method of driving a stepper motor in half-step mode. the currents are switched-on in the correct direction in sequence and no current control is required. the current is simply defined, a _ a b n _ b s a stator s n n s n ab rotor a n _ a s b n _ b s a n stator s n n s s n ab rotor a n _ a s b _ b a n stator n s s n s n b a rotor (a) same as figure a1(a) (b) half-step position (c) same as figure a1(b)
automotive, programmable stepper driver a3981 38 allegro microsystems, llc 115 northeast cutoff worcester, massachusetts 01615-0036 u.s.a. 1.508.853.5000; www.allegromicro.com in the first instance, by the resistance of the winding and the applied voltage. from figure a2(b) it is also apparent that varying the relative current in each phase will make it possible to move the rotor to any intermediate position between the four positions of figure a1, which occur when only a single phase is energized. when there is one intermediate position this is known as half step. when there are three intermediate positions this is known as quarter step and so on. higher resolution microstepping is described in more detail below. phase current-sequence diagrams figure a3 shows the full sequence of the two phase currents illus- trated in figure a2. this shows two electrical cycles, equivalent to 4 full mechanical steps (8 half steps). the full-step positions are marked f and the half-step positions are marked h . each half step in the electrical cycle is numbered, from 0 to 7, for reference later. this figure shows that, when discussing stepper motor control, it is necessary to know the relative magnitude and direction of the current in each phase. so, rather than use physical representations of the motor, such as in figure a1 and a2, or simple time-based current waveforms, such as figure a3, it is simpler to use a phase diagram. for a 2-pole bipolar motor this diagram is created by plotting the current in the two phases as orthogonal vectors, that is, as vectors at 90 to each other as shown in figure a4. phase current-phase diagrams figure a4 shows the currents of figure a3 plotted on a phase diagram where the phase a current is represented by the vertical line and the phase b current by the horizontal line. the half-step numbers correspond to the numbers in figure a3. for example, at step 1 in figure a3, the phase a current and the phase b cur- rent are both positive and with the same magnitude. these two currents are shown in figure a4 as the two solid arrows. adding these two current vectors together gives the resultant motor cur- rent vector indicated. the resultant is the hypotenuse of a right- angled triangle with the two other sides equal. if the other two sides are assumed to be 1 then the magnitude of the hypotenuse will be: 4 1 . 1 2 1 1 2 2 ? ? ? so the resultant current vector will be 141% of the value of the current in phase a or b, positioned at 45. torque ripple now, the torque output of any electrical motor is directly propor- tional to the magnitude of the motor current, and the motor cur- rent is the resultant phase current. it is clear from figure a4 that the resultant phase current at the half-step position is higher than the current at the full-step position. this means that the motor torque will be changing as the motor rotates, resulting in what is known as torque ripple . torque ripple in any rotating system will cause mechanical vibration and will result in increased audible noise and possible wear on other mechanical components. torque ripple can be reduced by ensuring that the resultant current at the half-step point has the same magnitude as the full current in the single phase at the full-step positions. f h f h f h f h f h f h f h f f h phase b current phase a current 0 1 2 3 4 5 6 7 0 1 2 3 4 5 6 6 7 f 0 1 2 3 4 5 6 7 h f f f h h h phase b current phase a current resultant figure a3. phase current sequence for uncompensated half step figure a4. phase diagram for uncompensated half step
automotive, programmable stepper driver a3981 39 allegro microsystems, llc 115 northeast cutoff worcester, massachusetts 01615-0036 u.s.a. 1.508.853.5000; www.allegromicro.com compensated half step figure a5 shows a circle superimposed on the phase diagram. this circle represents the required locus of the resultant phase cur- rent vectors to maintain 100% current magnitude. at the full-step positions, 0, 2, 4, and 6, only one phase is active and the magni- tude of the phase current is at 100%. at the half-step positions, 1, 3, 5, and 7, both phases are active. to ensure that the magnitude of the resultant current is 100%, the magnitude of each phase cur- rent must be 70.7%. calculating the value of the resultant current as before gives a resultant current of 100%. = 0.707 2 + 0.707 2 0.5 + 0.5 = 1 = 1 the current vectors at half-step position 1 are shown specifically to illustrate that the magnitude of the resultant sits on the 100% circle. for a standard stepper motor to operate with minimum torque ripple, the resultant current must always lie on the constant torque circle irrespective of the number of microsteps. for higher resolu- tion microstepping this then defines the relative phase currents at each microstep position. quarter step for example consider the next resolution in microstepping; quar- ter step. the locus of the required phase currents are shown in figure a6. the required current level in each phase can be calcu- lated using simple trigonometry. for example, consider microstep position 7 in figure a6 as detailed in figure a7. there are 4 quarter steps for each full step. a full step on the phase diagram is represented by 90. so each quarter step incre- ments the phase angle by 90 / 4 = 22.5. in figure a7 the resultant motor current at quarter-step position 8 is one quarter step from the horizontal, so it is at 22.5. the mag- nitude of the current in phase a at quarter-step position 7, i a7 , is therefore sin 22.5, which is equal to 0.383 or 38.3% of the maximum current. similarly, the magnitude of the current in phase b at quarter-step position 7, i b7 , is therefore cos 22.5, which is equal to 0.924 or 92.4% of the maximum current. at the 45 positions, 2, 6, 10 and 14, the magnitude of the current in phase a and phase b will be cos 45 = 0.707 or 70.7%, which is the same magnitude as in the half-step case shown in figure a5. due to symmetry, the phase a current is the same at quarter-step positions 7 and 1. the phase a current at quarter-step positions 9 and 15 also has the same magnitude, but the current is in the f 0 1 2 3 4 5 6 7 h f f f h h h phase b current phase a current resultant i a 0 1 2 3 4 5 6 7 i b 8 9 10 11 12 13 14 15 i a 6 7 8 i b i a7 i b7 =-cos22.5 22.5 =sin22.5 figure a5. phase diagram for compensated half step figure a6. phase diagram for quarter step figure a7. calculating phase current magnitudes
automotive, programmable stepper driver a3981 40 allegro microsystems, llc 115 northeast cutoff worcester, massachusetts 01615-0036 u.s.a. 1.508.853.5000; www.allegromicro.com opposite direction. in addition the phase b current at quarter- step positions 3, 5, 11, and 13 also have the same magnitude as that of phase a at quarter-step position 7, with a positive current direction for steps 3 and 13 and a negative direction for steps 5 and 11. similar symmetry can be applied to the phase b current at quarter-step position 7, calculated above. this means that only five discrete current magnitudes are required, including 0% and 100%, in order to drive the stepper motor to all 16 quarter-step positions. using the same nomencla- ture as figure a7, that is, i pn , where p is the phase, a or b, and n is the quarter-step number from figure a6, table a1 shows where each of the five magnitude values are used. figure a8 shows these values plotted as a current sequence diagram. this figure is therefore the time-based equivalent of the phase diagram in figure a6. higher microstep resolution the principles described above can easily be extended to higher microstep resolutions. as the microstep resolution increases, it becomes more apparent that the phase current sequences approxi- mate ever closer to a sin and cosine function. figure a9 shows the measured phase current sequence of the a3981 running in sixteenth-step mode. the phase current sequences for eighth-step and sixteenth-step resolutions are shown in figures a10 and a11. most applications using small motors are limited to sixteenth-step mode due to the mechanical precision of the motor. larger, high- precision stepper motors are sometimes driven at 32, 64, or even up to 256 microsteps in some extreme cases. practical implementation a system to drive a stepper motor with microstep capability requires sequencers, current reference generators, and current controllers. developing such a system from discrete components, or even using a fast microcontroller, is a complex task. the a3981 is one of several fully integrated stepper drivers that are available with microstep resolutions, from compensated half step to sixteenth step and higher, using programmable current tables. all aspects of the stepper control system are included in these single chip solutions and many of them can be controlled by a simple step and direction interface. table a1. quarter-step phase current magnitudes magnitude (%) phase b phase a 0 . i a0 ?i a8 ??i b4 ?i b12 38.3 i a1 i a7 i a9 i a15 i b3 i b5 i b11 i b13 70.7 i a2 i a6 i a10 i a14 i b2 i b6 i b10 i b14 92.4 i a3 i a5 i a11 i a13 i b1 i b7 i b9 i b15 100 . ?i a4 ?i a12 i b0 ?i b8 ? i b 14 15 0 1 2 3 4 5 6 7 8 9 10 11 12 12 13 i a 38% 70% 92% 100% 0 -38% -70% -92% -100% 38% 70% 92% 100% 0 -38% -70% -92% -100% figure a8. phase current sequence for quarter step figure a9. measured sixteenth-step phase current sequence
automotive, programmable stepper driver a3981 41 allegro microsystems, llc 115 northeast cutoff worcester, massachusetts 01615-0036 u.s.a. 1.508.853.5000; www.allegromicro.com practical limitations the information presented here assumes ideal stepper motors being stepped slowly, with accurate, efficient current control circuits. in practice the stepper motor phase windings are repre- sented by two non-ideal inductors and the motor may be driven at a high stepping rate. a high stepping rate will produce a back emf, like any other motor, that will act against any current control circuits. the current control circuits must also be able to work with inductive loads. in general the current control circuit will be a pwm cur- rent control scheme to make the driver as efficient as possible and reduce the dissipation in the driver. like any other motor, the back emf will also limit the maximum stepping rate of the motor. as the motor speed increases the back emf will increase. when it reaches a value close to the supply voltage the resulting voltage difference will be insufficient to drive the phase current required to produce the necessary output torque. when this occurs the motor will stall and slip out of syn- chronization with the driving circuit. the mechanical precision of the motor will also have an effect on the overall performance of the system. if the effect of the motor windings on the rotor are non-linear then the relationship between current and torque may not be linear. the magnitude of the currents at each microstep may then require a relationship other than sinusoidal. the a3981 and a few other integrated driv- ers are able to accommodate this by allowing the phase current values for each microstep position to be reprogrammed. in most systems this effect will be very small and can be ignored but in some cases some improvement in torque ripple and audible noise can be achieved. figure a10. phase current sequence for eighth step 1 00% 98% 9 2 % 83% 70% 56% 38% 1 9% 1 9% 38% 56% 70% 83% 9 2 % 98% 1 00% 1 00% 98% 9 2 % 83% 70% 56% 38% 1 9% 1 9% 38% 56% 70% 83% 9 2 % 98% 1 00% i b i a 0 1 2 3 45678910111213141516171819 20 21 22 23 24 24 25 26 27 28 29 30 31
automotive, programmable stepper driver a3981 42 allegro microsystems, llc 115 northeast cutoff worcester, massachusetts 01615-0036 u.s.a. 1.508.853.5000; www.allegromicro.com 1 00% 98% 9 2 % 83% 70% 56% 38% 1 9% 1 9% 38% 56% 70% 83% 9 2 % 98% 1 00% i b 1 0% 2 9% 4 7% 63% 77% 88% 96% 99% 1 0% 2 9% 4 7% 63% 77% 88% 96% 99% 1 00% 98% 9 2 % 83% 70% 56% 38% 1 9% 1 9% 38% 56% 70% 83% 9 2 % 98% 1 00% 1 0% 2 9% 4 7% 63% 77% 88% 96% 99% 1 0% 2 9% 4 7% 63% 77% 88% 96% 99% i a figure a11. phase current sequence for sixteenth step
automotive, programmable stepper driver a3981 43 allegro microsystems, llc 115 northeast cutoff worcester, massachusetts 01615-0036 u.s.a. 1.508.853.5000; www.allegromicro.com for the latest version of this document, visit our website: www.allegromicro.com copyright ?2010-2013, allegro microsystems, llc allegro microsystems, llc reserves the right to make, from time to time, such de par tures from the detail spec i fi ca tions a s may be required to permit improvements in the per for mance, reliability, or manufacturability of its products. before placing an order, the user is cautioned to verify that the information being relied upon is current. allegro?s products are not to be used in life support devices or systems, if a failure of an allegro product can reasonably be expected to cause the failure of that life support device or system, or to affect the safety or effectiveness of that device or system. the in for ma tion in clud ed herein is believed to be ac cu rate and reliable. how ev er, allegro microsystems, llc assumes n o re spon si bil i ty for its use; nor for any in fringe ment of patents or other rights of third parties which may result from its use. revision history revision revision date description of revision rev. 4 june 21, 2012 update electrical characteristics table


▲Up To Search▲   

 
Price & Availability of A3981V

All Rights Reserved © IC-ON-LINE 2003 - 2022  

[Add Bookmark] [Contact Us] [Link exchange] [Privacy policy]
Mirror Sites :  [www.datasheet.hk]   [www.maxim4u.com]  [www.ic-on-line.cn] [www.ic-on-line.com] [www.ic-on-line.net] [www.alldatasheet.com.cn] [www.gdcy.com]  [www.gdcy.net]


 . . . . .
  We use cookies to deliver the best possible web experience and assist with our advertising efforts. By continuing to use this site, you consent to the use of cookies. For more information on cookies, please take a look at our Privacy Policy. X